public class DiagramProperties extends Object
Constructor and Description |
---|
DiagramProperties() |
Modifier and Type | Method and Description |
---|---|
static DiagramProperty |
createBoolean(GraphElement element,
String propertyID,
boolean value)
Creates a MagicDraw Boolean Diagram Property
|
static DiagramProperty |
createChoice(GraphElement element,
String propertyID,
List<String> choices,
int choice)
Creates a MagicDraw Choice Diagram Property.
|
static DiagramProperty |
createChoice(GraphElement element,
String propertyID,
List<String> choices,
String choice)
Creates a MagicDraw Choice Diagram Property.
|
static DiagramProperty |
createColor(GraphElement element,
String propertyID,
float colorValue)
Creates a MagicDraw Color Diagram Property.
|
static DiagramProperty |
createFont(GraphElement element,
String propertyID,
String fontName,
int size,
int style)
Creates a MagicDraw Font Diagram Property.
|
static List<String> |
getChoices(GraphElement graphElement,
String propertyID)
Returns a List of Strings corresponding to the possible values of the MagicDraw Choice Property.
|
static int |
getFontSize(GraphElement graphElement)
Returns the size of the MagicDraw Font Diagram Property.
|
static int |
getFontStyle(GraphElement graphElement)
Returns the style of the MagicDraw Font Diagram Property.
|
public static DiagramProperty createBoolean(GraphElement element, String propertyID, boolean value)
element
- the Graphical ElementpropertyID
- the property keyvalue
- the boolean value to setpublic static DiagramProperty createChoice(GraphElement element, String propertyID, List<String> choices, int choice)
element
- the Graphical ElementpropertyID
- the property keychoices
- the list of possible valueschoice
- the index of the valuepublic static DiagramProperty createChoice(GraphElement element, String propertyID, List<String> choices, String choice)
element
- the Graphical ElementpropertyID
- the property keychoices
- the list of possible valueschoice
- the valuepublic static DiagramProperty createColor(GraphElement element, String propertyID, float colorValue)
element
- the Graphical ElementpropertyID
- the property keycolorValue
- the value of the colorpublic static DiagramProperty createFont(GraphElement element, String propertyID, String fontName, int size, int style)
element
- the Graphical ElementpropertyID
- the property keyfontName
- the name of the fontsize
- the size of the fontstyle
- the style of the fontpublic static int getFontStyle(GraphElement graphElement)
graphElement
- the Graphical Elementpublic static int getFontSize(GraphElement graphElement)
graphElement
- the Graphical Elementpublic static List<String> getChoices(GraphElement graphElement, String propertyID)
graphElement
- the Graphical ElementpropertyID
- the property id