Metal 8.0.0
This release adds two major enhancements:
- The
Scope
ValueExpression
allows referencing values inside a dynamically constructed scope, useful for referencing values inside a specific part of the structure. This is especially useful for data structures that have many repeating structures:Scope
makes it much easier to reference the current, local version of a value. - The
CurrentIteration
ValueExpression
allows referencing the count of a running iteration (e.g., when inside an iteratingToken
such asRep
,RepN
orWhile
). Passing a value allows referencing multiple levels of iteration (0=current, 1=parent, 2=parent-of-parent, etc.)
Additionally, the code has been cleaned up and improved in many ways. Most significantly:
- Instead of returning
ImmutableList<Optional<Value>>
from evaluating aValueExpression
, this now returns anImmutableList<Value>
. To signify the absence of a value, there is now aNOT_A_VALUE
constant, that replacesempty()
instances inside the list of results. - There are
ValueExpression
implementations that always return a single value (e.g.,Last
or any of theFold*
). To enhance the typing of theseValueExpression
s, there is now aSingleValueExpression
that derives fromValueExpression
and provides anevalSingle(...)
method that directly returns anOptional<Value>
.
Apart from these changes, many small fixes have been performed based on applying many new build and analysis tools on our code base, including CI on Windows.
Note: From Metal 9.x.x onward, the required version of Java will change from at least 8 to at least 11 (or higher, depending on when it will be released).
For a more detailed description, please see the 8.0.0 Milestone.