XPRMUserType
- java.lang.Object
-
- com.dashoptimization.XPRMUserType
-
- All Implemented Interfaces:
- XPRMIdentifier, XPRMTyped
public class XPRMUserType extends java.lang.ObjectA user type.
-
-
Field Summary
-
Fields inherited from interface com.dashoptimization.XPRMTyped
GRP_DYN, GRP_GEN, MSK_FIX, MSK_GRP, MSK_STR, MSK_TYP, STR_ARRAY, STR_CONST, STR_CSREF, STR_LIST, STR_MEM, STR_NTYP, STR_PROB, STR_PROC, STR_REC, STR_REF, STR_SET, STR_UTYP, TYP_BOOL, TYP_EXTN, TYP_INT, TYP_LINCTR, TYP_MPVAR, TYP_NOT, TYP_REAL, TYP_STRING
-
-
Method Summary
Modifier and Type Method and Description XPRMProblemCompscomponents()Get an iterator to enumerate all components of the problem.XPRMTypedexpand()Expand the type.XPRMRecordFieldsfields()Get an iterator to enumerate all fields of a record.java.lang.StringgetName()Get the identifier name.intgetStructCode()Structure code.java.lang.StringgetStructName()String representation of structure.intgetTypeCode()Type code.java.lang.StringgetTypeName()String representation of type.booleanisProblem()Check whether the type is a problem.java.lang.StringtoString()
-
-
-
Method Detail
-
fields
public XPRMRecordFields fields()
Get an iterator to enumerate all fields of a record.- Returns:
-
A field iterator if the type is a record,
nullotherwise
-
components
public XPRMProblemComps components()
Get an iterator to enumerate all components of the problem.- Returns:
-
A problem component iterator if the type is a problem,
nullotherwise
-
isProblem
public boolean isProblem()
Check whether the type is a problem.- Returns:
-
trueif the type is a problem
-
expand
public XPRMTyped expand()
Expand the type.- Returns:
-
A type object (
XPRMUserType,XPRMNativeTypeorXPRMType) orthisif the type is a record or a problem
-
getTypeName
public java.lang.String getTypeName()
Description copied from interface:XPRMTypedString representation of type.- Specified by:
-
getTypeNamein interfaceXPRMTyped - Returns:
- Type name
-
getStructCode
public int getStructCode()
Description copied from interface:XPRMTypedStructure code. The code is one of theSTR_*values.- Returns:
- Encoded structure
-
getStructName
public java.lang.String getStructName()
Description copied from interface:XPRMTypedString representation of structure.- Returns:
- Structure name
-
toString
public java.lang.String toString()
- Overrides:
-
toStringin classjava.lang.Object
-
getTypeCode
public final int getTypeCode()
Description copied from interface:XPRMTypedType code. The code is one of theTYP_*values.- Specified by:
-
getTypeCodein interfaceXPRMTyped - Returns:
- Encoded type
-
getName
public java.lang.String getName()
Description copied from interface:XPRMIdentifierGet the identifier name.- Specified by:
-
getNamein interfaceXPRMIdentifier - Returns:
- The identifier name
-
-
