Added an Enum and changed the name of DiagramObject