ModelEntity
Example
// to fetch a ModelEntity from a project var entity = insight .getView() .getProject() .getModelSchema() .getEntity('ENTITY_NAME'); // to fetch an ModelEntity from a scenario instance var entity = scenario .getModelSchema() .getEntity('ENTITY_NAME');
Method summary
name | description |
---|---|
getAbbreviation | The abbreviation for this entity. |
getAlias | The alias for this entity. |
getElementType | The data type of the elements held in this Array or Set. |
getFormat | Entity formatting string |
getIndexGroupings | The names of the entities that can be used to group the Elements in this array. |
getIndexSets | The names of the entities used to index the elements in this array. |
getLabelsEntity | The name of the entity that holds the labels for this entity. |
getManagementType | Indicates whether this data is part of the input data or results. |
getName | The name of this entity. |
getType | The data type of this entity. |
getViolationCostEntity | The name of the entity that contains the costs of relaxing this constraint. |
getViolationUpperBoundEntity | The name of the entity that contains the upper bounds of the violation of the relaxed constraints. |
isAlwaysHidden | Indicates whether the model entity is always hidden. |
isConstant | Indicates whether this entity's value is a constant. |
isDisableable | Indicates that this constraint entity can be disabled. |
isHidden | Indicates whether the model entity is hidden. |
isIndexGrouping | Indicates whether this entity is used as an Index Grouping. |
isRelaxable | Indicates that this constraint entity can be relaxed. |
Methods
- getAbbreviation ( ) → {string}
-
The abbreviation for this entity. Will fallback to alias and then name if the entity has no abbreviation or alias respectively.
detailsReturns:returns tableType Description typestringThe abbreviation for this entity. Fallback to alias and name. Example
examples
Back to Topentity.getAbbreviation();
- getAlias ( ) → {string}
-
The alias for this entity. Will fallback to name if the entity has no alias.
detailsReturns:returns tableType Description typestringThe alias for this entity. Fallback to entity name. Example
examples
Back to Topentity.getAlias();
- getElementType ( ) → {insight.enums.DataType}
-
The data type of the elements held in this Array or Set.
detailsReturns:returns tableType Description typeinsight.enums.DataTypethe data type of the elements, or nullif the entity is not an Array or a Set Example
examples
Back to Topentity.getElementType();
- getFormat ( ) → {string}
-
Entity formatting string
detailsReturns:returns tableType Description typestringformatting string Example
examples
Back to Topentity.getFormat();
- getIndexGroupings ( ) → {Array.<string>}
-
The names of the entities that can be used to group the Elements in this array.
e.g. An array indexed by Month can be grouped by Quarters.detailsReturns:returns tableType Description typeArray.<string>The names of the entities that can be used to group the Elements in this array Example
examples
Back to Topvar array = entity.getIndexGroupings();
- getIndexSets ( ) → {Array.<string>}
-
The names of the entities used to index the elements in this array.
detailsReturns:returns tableType Description typeArray.<string>The names of the entities used to index the elements in this array, or null if the entity is not an array. Example
examples
Back to Topvar array = entity.getIndexSets();
- getLabelsEntity ( ) → {string}
-
The name of the entity that holds the labels for this entity.
detailsReturns:returns tableType Description typestringThe name of the entity that holds the labels for this entity Example
examples
Back to Topentity.getLabelsEntity();
- getManagementType ( ) → {insight.enums.EntityManagementType}
-
Indicates whether this data is part of the input data or results.
detailsReturns:returns tableType Description typeinsight.enums.EntityManagementTypeIndicates whether this data is part of the input data or results Example
examples
Back to Topentity.getManagementType();
- getName ( ) → {string}
-
The name of this entity.
detailsReturns:returns tableType Description typestringThe name of this entity Example
examples
Back to Topentity.getName();
- getType ( ) → {insight.enums.DataType}
-
The data type of this entity.
detailsReturns:returns tableType Description typeinsight.enums.DataTypeThe data type of this entity Example
examples
Back to Topentity.getType();
- getViolationCostEntity ( ) → {string}
-
The name of the entity that contains the costs of relaxing this constraint.
detailsReturns:returns tableType Description typestringthe name of the violation cost entity Example
examples
Back to Topentity.getViolationCostEntity();
- getViolationUpperBoundEntity ( ) → {string}
-
The name of the entity that contains the upper bounds of the violation of the relaxed constraints.
detailsReturns:returns tableType Description typestringthe name of the violation upper bounds entity Example
examples
Back to Topentity.getViolationUpperBoundEntity();
- isAlwaysHidden ( ) → {boolean}
-
Indicates whether the model entity is always hidden.
detailsReturns:returns tableType Description typebooleantrue if the model entity is always hidden, otherwise false Example
examples
Back to Topentity.isAlwaysHidden();
- isConstant ( ) → {boolean}
-
Indicates whether this entity's value is a constant.
detailsReturns:returns tableType Description typebooleantrue if this entity's value is a constant, otherwise false Example
examples
Back to Topentity.isConstant();
- isDisableable ( ) → {boolean}
-
Indicates that this constraint entity can be disabled.
detailsReturns:returns tableType Description typebooleantrue if this constraint can be disabled, otherwise false Example
examples
Back to Topentity.isDisableable();
- isHidden ( ) → {boolean}
-
Indicates whether the model entity is hidden.
detailsReturns:returns tableType Description typebooleantrue if the model entity is hidden or always hidden, otherwise false Example
examples
Back to Topif (entity.isHidden()) { // do something if entity is hidden }
- isIndexGrouping ( ) → {boolean}
-
Indicates whether this entity is used as an Index Grouping.
detailsReturns:returns tableType Description typebooleantrue if this entity is used as an Index Grouping, otherwise false Example
examples
Back to Topif (entity.isIndexGrouping()) { // do something if entity is index grouping. }
- isRelaxable ( ) → {boolean}
-
Indicates that this constraint entity can be relaxed.
detailsReturns:returns tableType Description typebooleantrue if this constraint can be relaxed, otherwise false Example
examples
Back to Topif (entity.isRelaxable) { // do something if entity can be relaxed }
© 2001-2019 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.