Class OrderedEnum
- java.lang.Object
-
- net.ssehub.easy.varModel.model.ModelElement
-
- net.ssehub.easy.varModel.model.ContainableModelElement
-
- net.ssehub.easy.varModel.model.datatypes.CustomDatatype
-
- net.ssehub.easy.varModel.model.datatypes.Enum
-
- net.ssehub.easy.varModel.model.datatypes.OrderedEnum
-
- All Implemented Interfaces:
IDatatype,IDatatypeVisitable,IModelElement
public class OrderedEnum extends Enum
Enumerations allow the definition of sets of named values.- Author:
- heiko beck, Holger Eichelberger
-
-
Field Summary
Fields Modifier and Type Field Description (package private) static DelegatingTypeDTYPEstatic OperationGREATERstatic OperationGREATER_EQUALSstatic OperationLESSstatic OperationLESS_EQUALSstatic OperationMAXstatic OperationMINstatic IDatatypeTYPEThis constant represents the common type of all enums.-
Fields inherited from class net.ssehub.easy.varModel.model.datatypes.Enum
ASSIGNMENT, EQUALS, IS_DEFINED, NOTEQUALS, NOTEQUALS_ALIAS, ORDINAL, TYPE_OF
-
-
Constructor Summary
Constructors Modifier Constructor Description privateOrderedEnum()Creates the singleton instance forTYPE.OrderedEnum(java.lang.String name, ModelElement parent)Constructor for an empty enum.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(IDatatypeVisitor visitor)Accepts a specialized visitor for creating a textual representation of the identity of this type.voidaccept(IModelVisitor visitor)Accept method for the visitor.booleanisOrdered()Returns whether this enum is ordered.-
Methods inherited from class net.ssehub.easy.varModel.model.datatypes.Enum
add, get, getLiteral, getLiteralByOrdinal, getLiteralCount, getLiteralIndex, has
-
Methods inherited from class net.ssehub.easy.varModel.model.datatypes.CustomDatatype
getGenericType, getGenericTypeCount, getOperation, getOperationCount, getType, getTypeClass, isAssignableFrom, isPrimitive, isPseudoType, isType
-
Methods inherited from class net.ssehub.easy.varModel.model.ContainableModelElement
getNameSpace, getParent, getProject, getQualifiedName, getTopLevelParent, isTopLevel, setParent
-
Methods inherited from class net.ssehub.easy.varModel.model.ModelElement
findAttribute, getComment, getName, getUniqueName, isTransparent, propagateAttribute, setComment, setName, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface net.ssehub.easy.varModel.model.datatypes.IDatatype
getName, getNameSpace, getQualifiedName, getUniqueName
-
-
-
-
Field Detail
-
DTYPE
static final DelegatingType DTYPE
-
TYPE
public static final IDatatype TYPE
This constant represents the common type of all enums. Each specific enum type is assignable to this type.
-
GREATER
public static final Operation GREATER
-
LESS
public static final Operation LESS
-
GREATER_EQUALS
public static final Operation GREATER_EQUALS
-
LESS_EQUALS
public static final Operation LESS_EQUALS
-
MIN
public static final Operation MIN
-
MAX
public static final Operation MAX
-
-
Constructor Detail
-
OrderedEnum
private OrderedEnum()
Creates the singleton instance forTYPE.
-
OrderedEnum
public OrderedEnum(java.lang.String name, ModelElement parent)Constructor for an empty enum.- Parameters:
name- Name of the enumparent- the object, in which this specific one is embedded
-
-
Method Detail
-
isOrdered
public boolean isOrdered()
Returns whether this enum is ordered.
-
accept
public void accept(IModelVisitor visitor)
Accept method for the visitor.- Specified by:
acceptin interfaceIModelElement- Overrides:
acceptin classEnum- Parameters:
visitor- The visitor, which should process this model element.
-
accept
public void accept(IDatatypeVisitor visitor)
Description copied from interface:IDatatypeVisitableAccepts a specialized visitor for creating a textual representation of the identity of this type.- Specified by:
acceptin interfaceIDatatypeVisitable- Overrides:
acceptin classEnum- Parameters:
visitor- the visitor to accept
-
-