eclipse-gmf


How To Obtain All the Nodes and Connections After Launching the GMF Project


After launching the GMF project, I get a new window to make my own model.
After placing some nodes and connections, I should calculate according to their attributes. At first, HOW can I obtain all the information of every node and every connection?
First , let's get the relevant editor:
DomainDiagramEditor d= (DomainDiagramEditor) PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor();
Now, you can either get all the editparts in your diagram , getting the relevant model from them:
final List children = d.getDiagramEditPart().getChildren();
gets you a list of EditParts.
Or, you can get the model objects directly with:
EObject element = d.getDiagram().getElement();
EList<EObject> eContents_ = element.eContents();
That gives you a list of all the model objects in the active editor.
Hope that answers your question

Related Links

selecting one Node (along with inside edges) from CSSDiagramImpl file and saving it in a new file
Managed layout in an EuGENia script
How to make lifeline shape in GMF?
Printing GMF diagrams using PDFCreator not able to open the generated pdf
GMF change the colour of a connection
Eclipse GMF Model selected Wizward could not be started
GMF how to create different shapes for link decorations
What is this error Phantom nodes that are not targeted by a link mapping representing containment reference present in model
How To Obtain All the Nodes and Connections After Launching the GMF Project
Starting with Eclipse GMF

Categories

HOME
tomcat
haproxy
plpgsql
openlayers-3
flurry
cisco
swarm
locationmanager
colors
smooks
mailmerge
jquery-select2-4
angular4
google-awareness
rest-assured
word2vec
parceler
kaggle
chronicle-queue
restier
dragula
uri
offline-caching
acrobat
spring-annotations
laravel-4.2
bitbake
ibm-connections
monitor
d3.js-v4
location-services
payeezy
buildforge
keyboard-layout
formsauthenticationticket
unification
rdp
game-center
icepdf
deployd
non-linear-regression
sonicmq
gestures
sonatype
android-sharing
alertify
openerp-6
pbx
petsc
cefpython
deviare
mathjs
nsdata
bbc-micro
swiffy
polymerfire
univocity
android-expansion-files
pack
deeplink
openshift-cartridge
chicagoboss
dsa
jnlp
ngcordova
sequence-sql
cache-manifest
kotlin-android-extensions
subfolder
mgwt
jcheckbox
password-recovery
webmethod
accessory
proxy-server
vlab
eager-loading
rikulo
jbox2d
towers-of-hanoi
uitextfielddelegate
java.lang.class
prefuse
nsfont
boost-foreach
net-use
office-automation
rtd
digiflow
resharper-5.0
rational-unified-process
google-translator-toolkit
main-method
motif
efs
regioninfo
chronic

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App