Package adams.core.base
Class Mat5ArrayDimensions
- java.lang.Object
-
- adams.core.base.BaseObject
-
- adams.core.base.AbstractBaseString
-
- adams.core.base.Mat5ArrayDimensions
-
- All Implemented Interfaces:
CloneHandler<BaseObject>
,Serializable
,Comparable
public class Mat5ArrayDimensions extends AbstractBaseString
For specifying the dimensions of a Matlab matrix.- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
SEPARATOR
the separator between dimensions.-
Fields inherited from class adams.core.base.BaseObject
m_Internal, m_Properties, SUFFIX_DISPLAY, SUFFIX_VALUE
-
-
Constructor Summary
Constructors Constructor Description Mat5ArrayDimensions()
Initializes the index with no index (empty string).Mat5ArrayDimensions(int[] index)
Initializes the index with the specified index array.Mat5ArrayDimensions(String index)
Initializes the index with the specified string.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getTipText()
Returns a tool tip for the GUI editor (ignored if null is returned).int[]
indexValue()
Returns the value as dimensional index.boolean
isValid(String value)
Checks whether the string value is a valid presentation for this class.-
Methods inherited from class adams.core.base.AbstractBaseString
convert, getValue, initialize, isEmpty, length, setValue, stringValue
-
Methods inherited from class adams.core.base.BaseObject
compareTo, equals, getClone, getInternal, getTemplates, getUnicode, hasFavoritesSupport, hashCode, isValidUnicode, newInstance, setUnicode, toObjectArray, toObjectArray, toString, toStringArray, toStringList
-
-
-
-
Field Detail
-
SEPARATOR
public static final String SEPARATOR
the separator between dimensions.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
Mat5ArrayDimensions
public Mat5ArrayDimensions()
Initializes the index with no index (empty string).
-
Mat5ArrayDimensions
public Mat5ArrayDimensions(String index)
Initializes the index with the specified string.- Parameters:
index
- the index
-
Mat5ArrayDimensions
public Mat5ArrayDimensions(int[] index)
Initializes the index with the specified index array.- Parameters:
index
- the index
-
-
Method Detail
-
isValid
public boolean isValid(String value)
Checks whether the string value is a valid presentation for this class.- Overrides:
isValid
in classAbstractBaseString
- Parameters:
value
- the string value to check- Returns:
- true if non-null
-
indexValue
public int[] indexValue()
Returns the value as dimensional index. Uses -1 for unspecified/empty dimensions (eg for iterating).- Returns:
- the array of positions, empty array if nothing specified
-
getTipText
public String getTipText()
Returns a tool tip for the GUI editor (ignored if null is returned).- Specified by:
getTipText
in classAbstractBaseString
- Returns:
- the tool tip
-
-