Skip to content

GEF Edit Policy Reference Card

Last updated on 2013-04-26

I have a bad memory. No matter what happens I forget things. To cope with this, I try to write down everything I learn for future reference. So after developing a couple of GEF editors I think I can write down a small table of GEF edit policies, what each policy does, where they can be installed and how they work. This table will be updated as I learn more things.

LayoutEditPolicy
Used to create and move elements inside a container. This policy can also be used to create feedback before the user performs the operation

SelectionEditPolicy
Used to give feedback or perform special actions when an EditPart is selected

ComponentEditPolicy
Used to delete a NodeEditPart (nodes in the editor)

ConnectionEditPolicy
Used to delete a ConnectionEditPart (links in the editor)

ContainerEditPart
Used to create elements inside a container.

DirectEditPolicy
Used to show “direct edit” of a property inside the GraphicalEditPart. This is the policy used to create an editable textbox inside a model element to edit one of the element’s properties – usually its name.

Enhanced by Zemanta
Published inProgramming

Be First to Comment

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.