|Initialize programmatically created nodes [message #870207]
||Mon, 07 May 2012 09:26
| Jérémy Flusin
Registered: May 2012
My problem is quite simple: I create "Input" nodes programmatically this way:
CreateViewRequest createInputViewAndElementRequest = CreateViewRequestFactory.getCreateShapeRequest(
Command createInputNodeCommand = cmep.getCommand(createInputViewAndElementRequest);
Where "cmep" is the appropriate EditPart and "cc" is a CompoundCommand I created before. Everything here works fine.
My "Input" nodes have "Description" and "ID" fields visible in the "Properties" view panel when my editor is launched. All I want to do is to set these parameters when I create my node programmatically.
I tried to use the "CreateViewRequest::setExtendedData()" method but I'm not even sure of its purpose. Moreover, I'm not sure of what the map argument should contain.
I also tried to get the factory of my request, but since the method "CreateViewRequest::getFactory()" is protected I couldn't.
What is the easiest way to do this ?
[Updated on: Mon, 07 May 2012 09:31]
Report message to a moderator
Powered by FUDForum
. Page generated in 0.02934 seconds