Package com.nomagic.magicdraw.properties
Class ClassPathEntriesListProperty
java.lang.Object
com.nomagic.magicdraw.properties.Property
com.nomagic.magicdraw.properties.ListProperty
com.nomagic.magicdraw.properties.ClassPathEntriesListProperty
- All Implemented Interfaces:
PropertyVisitorAcceptor
,Cloneable
ClassPathEntriesListProperty
represents a property for storing and
editing entries of the classpath.-
Field Summary
Fields inherited from class com.nomagic.magicdraw.properties.Property
DEFAULT_PROPERTY_RESOURCE_PROVIDER, EDITABLE, NULL, NULL_ID_PROPERTY_RESOURCE_PROVIDER, TO, UNDEFINED, VALUE, VALUE_ANNOTATIONS
-
Constructor Summary
ConstructorDescriptionCreates and initializes a newClassPathEntriesListProperty
object.ClassPathEntriesListProperty
(String id, Object[] value, boolean allowFiles) Creates and initializes a newClassPathEntriesListProperty
object from specified parameters. -
Method Summary
Modifier and TypeMethodDescriptionvoid
accept
(PropertyVisitor visitor) Accepts the given visitor.protected boolean
areValuesEqual
(Object oldValue, Object newValue) Check if values are equal before setting new value.clone()
Clones the property.Returns a class type of the property.File[]
getFiles()
Returns an array of files.String[]
Returns value's string representation.boolean
void
setAllowsFiles
(boolean allow) Methods inherited from class com.nomagic.magicdraw.properties.ListProperty
getValue, setValue
Methods inherited from class com.nomagic.magicdraw.properties.Property
_getValue, _isFrozen, _setFrozen, _setValue, addAnnotation, addPropertyChangeListener, addSource, addSources, areEqualByValue, checkFrozen, checkFrozen, createCellEditor, createTableCellRenderer, equals, firePropertyChange, generateDefaultDescriptionID, getAdditionalProperties, getAdditionalProperty, getAnnotation, getAnnotations, getDescription, getDescriptionID, getFirstElementFromSources, getGroup, getID, getIntroductoryVersion, getName, getNonEditableReason, getProjectFromSourcesOrActive, getPureDescription, getResourceProvider, getResourceProviderID, getSortableValueStringRepresentation, getSourceAsElement, getSources, getSourcesAsStream, getUndefinedString, getUndefinedString, hashCode, isEditable, isUndefinedState, isValueCompatible, removeAnnotation, removePropertyChangeListener, setAdditionalProperties, setAdditionalProperty, setAnnotations, setDescription, setDescriptionID, setEditable, setGroup, setID, setIntroductoryVersion, setNonEditableReason, setResourceProvider, setResourceProviderID, setSources, setUndefinedState, toString
-
Constructor Details
-
ClassPathEntriesListProperty
public ClassPathEntriesListProperty()Creates and initializes a newClassPathEntriesListProperty
object. -
ClassPathEntriesListProperty
Creates and initializes a newClassPathEntriesListProperty
object from specified parameters.- Parameters:
id
- - id of the propertyvalue
- - a value of the property
-
-
Method Details
-
getClassType
Returns a class type of the property.- Specified by:
getClassType
in interfacePropertyVisitorAcceptor
- Overrides:
getClassType
in classListProperty
- Returns:
- PropertyID.CLASS_PATH_LIST_PROPERTY
- See Also:
-
accept
Description copied from class:ListProperty
Accepts the given visitor.- Specified by:
accept
in interfacePropertyVisitorAcceptor
- Overrides:
accept
in classListProperty
- Parameters:
visitor
- the PropertyVisitor.- Throws:
Exception
- See Also:
-
getFiles
Returns an array of files.- Returns:
- an array of files.
-
getFilesPaths
-
getFileProperties
-
isAllowsFiles
public boolean isAllowsFiles() -
setAllowsFiles
public void setAllowsFiles(boolean allow) -
getValueStringRepresentation
Description copied from class:Property
Returns value's string representation.- Overrides:
getValueStringRepresentation
in classListProperty
- Returns:
- string "null" if property does not have value;
value. toString()
if property has value.
-
areValuesEqual
Description copied from class:Property
Check if values are equal before setting new value. If values are equal value is not changed.- Overrides:
areValuesEqual
in classProperty
- Parameters:
oldValue
- current value.newValue
- new value.- Returns:
- true if values are equal.
-
clone
Description copied from class:Property
Clones the property. Clone is not deep, the clone will have the same instance of value. The clone will not have registered PropertyChangeListeners.- Overrides:
clone
in classListProperty
- Returns:
- the cloned property.
-