private void createSocketProperty(AbstractSocket socket, Sheet.Set sheetSet) {
try {
String connecteeType = socket.getConnecteeTypeName();
String connectionName = socket.getName();
PropertySupport.Reflection nextNodeProp =
new PropertySupport.Reflection(new ConnectionEditor(socket, this),
String.class,
"getConnectedToName",
"setConnectedToName");
nextNodeProp.setValue("canEditAsText", Boolean.TRUE);
nextNodeProp.setValue("suppressCustomEditor", Boolean.TRUE);
nextNodeProp.setName(connecteeType + ":" + connectionName);
PropertyEditorSupport editor = EditorRegistry.getEditor(connecteeType);
if (editor != null)
nextNodeProp.setPropertyEditorClass(editor.getClass());
sheetSet.put(nextNodeProp);
} catch (NoSuchMethodException ex) {
Exceptions.printStackTrace(ex);
}
}
OneComponentNode.java 文件源码
java
阅读 20
收藏 0
点赞 0
评论 0
项目:opensim-gui
作者:
评论列表
文章目录