Skip to content

Reference: value-model catalogue

Every value model in the framework, grouped by primary value type. The source of truth is Value.kt's discriminatorMapping — this page mirrors it with one-line descriptions and the operator extension that constructs each entry.

Drift-guard. A doc-build step re-reads Value.kt's discriminatorMapping and fails if any name is in code-but-not-doc or doc-but-not-code. If you add a new value model in the framework, add an entry here too.

For the conceptual overview, see concepts: value models. Operator naming follows: :operation: for unary/binary operators (plus, minus, not), :comparison: for comparators, :function: otherwise.

Boolean values (BooleanValue)

Discriminator Class Description
boolean:constant BooleanConstant Literal true / false. Lift via true.asValueModel().
boolean:reference BooleanReference Reference to a boolean field by ValueReference.
boolean:operation:not BooleanOperationNot not(x).
boolean:operation:and BooleanOperationAnd a and b.
boolean:operation:or BooleanOperationOr a or b.
boolean:operation:xor BooleanOperationXor a xor b.
boolean:comparison:equal BooleanComparisonEqual a equal b.
boolean:comparison:not_equal BooleanComparisonNotEqual a notEqual b.
boolean:expression:select BooleanExpressionSelect select(c1 to v1, c2 to v2, …) returning a boolean.
boolean:conversion:to_string BooleanToStringValueConversion .toStringValue() (implicit in +).

Integer values (IntegerValue)

Discriminator Class Description
integer:constant IntegerConstant Literal integer. 42.asValueModel().
integer:reference IntegerReference Reference to an integer field.
integer:operation:plus IntegerOperationPlus a + b.
integer:operation:minus IntegerOperationMinus a - b.
integer:operation:times IntegerOperationTimes a * b.
integer:operation:div IntegerOperationDiv a / b (integer division).
integer:operation:rem IntegerOperationRem a % b.
integer:function:abs IntegerFunctionAbs abs(x).
integer:function:min IntegerFunctionMin min(a, b).
integer:function:max IntegerFunctionMax max(a, b).
integer:expression:select IntegerExpressionSelect select(...) returning an integer.
integer:comparison:less_than IntegerComparisonLessThan a lessThan b (returns BooleanValue).
integer:comparison:less_than_or_equal IntegerComparisonLessThanOrEqual a lessThanOrEqual b.
integer:comparison:greater_than IntegerComparisonGreaterThan a greaterThan b.
integer:comparison:greater_than_or_equal IntegerComparisonGreaterThanOrEqual a greaterThanOrEqual b.
integer:comparison:equal IntegerComparisonEqual a equal b.
integer:comparison:not_equal IntegerComparisonNotEqual a notEqual b.
integer:conversion:to_real IntegerToRealValueConversion Implicit in mixed-type arithmetic.
integer:conversion:to_string IntegerToStringValueConversion Implicit in StringValue + IntegerValue.
integer:conversion:to_dimensional_scalar IntegerToDimensionalScalarValueConversion Promote to a dimensional with a unit.
string:function:length StringLengthFunction s.length() returning an integer.
string:conversion:to_integer StringToIntegerValueConversion Parse a string to an integer.
real:conversion:to_integer RealToIntegerConversion Round / ceil / floor (RealToIntegerConversionType).
list:function:length ValueListFunctionSize list.length() size.
list:function:integer_sum ValueListFunctionIntegerSum Sum of an integer list.
entity_assignment_list:function:count_entities EntityAssignmentListFunctionCountEntities Count of entities.

Real values (RealValue)

Discriminator Class Description
real:constant RealConstant Literal double. 1.5.asValueModel().
real:reference RealReference Reference to a real field.
real:operation:plus / minus / times / div RealOperationPlus / Minus / Times / Div Standard arithmetic.
real:function:sin / cos / tan RealFunctionSin / Cos / Tan Trig.
real:function:asin / acos / atan RealFunctionASin / ACos / ATan Inverse trig.
real:function:atan2 RealFunctionATan2 atan2(y, x).
real:function:exp RealFunctionExp exp(x).
real:function:log / log10 RealFunctionLog / Log10 Natural / decimal log.
real:function:sqrt / cbrt RealFunctionSqrt / Cbrt Roots.
real:function:pow RealFunctionPow pow(base, exp).
real:function:abs / min / max RealFunctionAbs / Min / Max Absolute / extrema.
real:expression:select RealExpressionSelect select(...) returning a real.
real:comparison:* RealComparison* Same set as integers (LessThan, LessThanOrEqual, GreaterThan, GreaterThanOrEqual, Equal, NotEqual).
real:conversion:to_string RealToStringValueConversion Implicit in + "x".
real:conversion:to_dimensional_scalar RealToDimensionalScalarValueConversion Promote to a dimensional.
real:conversion:to_dimensional_vector DimensionalVectorFromComponents Build a vector from xyz reals.
string:conversion:to_real StringToRealValueConversion Parse a string to a real.
dimensional_scalar:conversion:to_real DimensionalScalarToRealValueConversion Strip units.
list:function:real_sum ValueListFunctionRealSum Sum of a real list.

String values (StringValue)

Discriminator Class Description
string:constant StringConstant Literal string. "x".asValueModel().
string:reference StringReference Reference to a string field.
string:operation:plus StringOperationPlus Concatenation.
string:function:lowercase / uppercase StringLowerCaseFunction / UpperCaseFunction Case.
string:function:substring StringSubStringFunction Substring with from / to.
string:function:starts_with / ends_with / contains StringStartsWithFunction / EndsWithFunction / ContainsFunction Predicates returning BooleanValue.
string:expression:select StringExpressionSelect select(...) returning a string.
string:comparison:equal / not_equal StringComparisonEqual / NotEqual Equality.

Enum values (EnumValue)

Discriminator Class Description
enum:constant EnumConstant Literal enum value. MyEnum.A.asValueModel().
enum:reference EnumReference Reference to an enum field.
enum:expression:select EnumExpressionSelect select(...) returning an enum.
enum:comparison:equal / not_equal EnumComparisonEqual / NotEqual Equality.
enum:function:one_of EnumFunctionOneOf e oneOf listOf(MyEnum.A, MyEnum.B).
enum:conversion:to_string EnumToStringValueConversion Implicit in +.

Measurement units (MeasurementUnitValue)

Discriminator Class Description
unit:constant MeasurementUnitConstant Literal unit.
unit:reference MeasurementUnitReference Reference to a unit field.
unit:operation:times / div MeasurementUnitOperationTimes / Div Compose units.
unit:function:pow MeasurementUnitFunctionPow Raise to a power.
unit:expression:select MeasurementUnitExpressionSelect select(...).
unit:comparison:equal / not_equal MeasurementUnitComparisonEqual / NotEqual Equality.

Dimensional scalars (DimensionalScalarValue)

Discriminator Class Description
dimensional_scalar:constant DimensionalScalarConstant Literal 5.meter.asValueModel().
dimensional_scalar:reference DimensionalScalarReference Reference to a dimensional scalar field.
dimensional_scalar:operation:plus / minus / times / div DimensionalScalarOperation* Unit-aware arithmetic.
dimensional_scalar:function:pow DimensionalScalarFunctionPow Raise to a power.
dimensional_scalar:expression:select DimensionalScalarExpressionSelect select(...).
dimensional_scalar:comparison:less_than / less_than_or_equal / greater_than / greater_than_or_equal DimensionalScalarComparison* Unit-aware comparisons.
dimensional_scalar:conversion:to_string DimensionalScalarToStringValueConversion Format with unit.
dimensional_vector:function:component DimensionalScalarFromDimensionalVectorComponent v.componentX() etc.
dimensional_vector:function:mag DimensionalVectorFunctionMag Vector magnitude → scalar.

Dimensional vectors (DimensionalVectorValue)

Discriminator Class Description
dimensional_vector:constant DimensionalVectorConstant Literal vector.
dimensional_vector:reference DimensionalVectorReference Reference to a dimensional vector field.
dimensional_vector:operation:plus / minus / times / div DimensionalVectorOperation* Unit-aware vector arithmetic.
dimensional_vector:function:norm DimensionalVectorFunctionNorm Normalize.
dimensional_vector:expression:select DimensionalVectorExpressionSelect select(...).
dimensional_vector:conversion:to_string DimensionalVectorToStringValueConversion Format.

Entity assignments

Discriminator Class Description
entity_assignment:constant EntityAssignmentConstant Literal entity reference.
entity_assignment:reference EntityAssignmentReference Reference field.
entity_assignment:function:is_empty EntityAssignmentFunctionIsEmpty Predicate.
entity_assignment:function:map_entities EntityAssignmentMapEntities Map across entities.
entity_assignment:conversion:to_string EntityAssignmentToStringValueConversion Format.
entity_assignment:conversion:to_markdown_link_string EntityAssignmentToMarkdownLinkValueConversion Markdown link form.
entity_assignment:conversion:to_entity_assignment_list EntityAssignmentToEntityAssignmentListValueConversion Promote to a list of one.

Entity assignment lists

Discriminator Class Description
entity_assignment_list:constant EntityAssignmentListConstant Literal list.
entity_assignment_list:reference EntityAssignmentListReference Reference field.
entity_assignment_list:function:is_empty EntityAssignmentListFunctionIsEmpty Predicate.
entity_assignment_list:function:count_entities EntityAssignmentListFunctionCountEntities Count.
entity_assignment_list:function:map_entities EntityAssignmentListMapEntities Map.
entity_assignment_list:conversion:to_markdown_link_string EntityAssignmentListToMarkdownLinkValueConversion Markdown link form.
entity_assignment_list:function:cad_predicate_failures EntityAssignmentListCadPredicateFailures The entities failing a CAD model query. Non-interactive rule sets only.
list:conversion:to_entity_assignment_list EntityAssignmentListFromComponents Build from a list.

Compounds (CompoundValue)

Discriminator Class Description
compound CompoundValue Compound record value. Field access via generated subclasses.
compound:expression:select CompoundExpressionSelect select(...) returning a compound; assigned to a value model field through its <field>Expression accessor.
compound:function:is_type PolymorphicCompoundTypeCheck c isTypeOf "TypeName" predicate.
compound:function:map_entities CompoundMapEntities Map across compound contents.

Lists (ValueList<T>)

Discriminator Class Description
list:constant ConstantValueList Literal list.
list:reference ReferenceValueList Reference to a list field.
list:function:is_empty ValueListFunctionIsEmpty Predicate.
list:function:is_not_empty ValueListFunctionIsNotEmpty Predicate.
list:function:any / all / none ValueListFunctionAny / All / None Quantifiers with a predicate lambda.
list:function:sublist ValueListFunctionSubList [from, to) slice.
list:function:take / take_last ValueListFunctionTake / TakeLast First / last n elements.
list:function:drop / drop_last ValueListFunctionDrop / DropLast Skip first / last n.
list:function:filter ValueListFunctionFilter Filter by predicate.
list:function:map ValueListFunctionMap Element-wise transform.
list:function:get ValueListFunctionGet list.get(i).
list:function:first / last ValueListFunctionFirst / Last Endpoints.
list:function:find ValueListFunctionFind First match by predicate.
list:operation:plus ValueListOperationPlus List concatenation.
list:operation:times ValueListOperationTimes List × scalar (repeat).
list:expression:select ValueListExpressionSelect select(...) returning a list.
list:generator:integer_sequence IntegerSequenceGenerator Generate [start, end, step] integers.
list:generator:real_sequence RealSequenceGenerator Same for reals.
value_list:conversion:to_string ValueListToStringValueConversion Format.

Dynamic casts

When you have a Value from a polymorphic context and know its concrete type:

Discriminator Class Description
dynamic_cast:as_boolean AsBooleanValue value.asBooleanValue().
dynamic_cast:as_enum AsEnumValue value.asEnumValue().
dynamic_cast:as_integer AsIntegerValue value.asIntegerValue().
dynamic_cast:as_real AsRealValue value.asRealValue().
dynamic_cast:as_string AsStringValue value.asStringValue().
dynamic_cast:as_list AsValueList value.asValueList<T>(elementModel = …).

A dynamic cast throws at evaluation time if the actual value isn't the asserted type. Prefer the typed accessors (configValueModel.foo) when you can — dynamic casts are for genuinely-unknown polymorphic contexts.

Cross-references