Enum YangXPathMathMode
- java.lang.Object
-
- java.lang.Enum<YangXPathMathMode>
-
- org.opendaylight.yangtools.yang.xpath.api.YangXPathMathMode
-
- All Implemented Interfaces:
Serializable
,Comparable<YangXPathMathMode>
@Beta public enum YangXPathMathMode extends Enum<YangXPathMathMode>
YangXPathParser
number compliance knobs. This enumeration defines what assumptions the parser can make -- affecting its optimization properties around constant folding when number expressions are involved.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description YangXPathMathSupport
getSupport()
ReturnYangXPathMathSupport
which provides support for the this mode.static YangXPathMathMode
valueOf(String name)
Returns the enum constant of this type with the specified name.static YangXPathMathMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
IEEE754
public static final YangXPathMathMode IEEE754
All number expressions are treated asdouble
. This in spirit of XPath 1.0 -- any number expression starts its life as a double, making all operations subject to IEEE754 rounding and range rules.
-
EXACT
public static final YangXPathMathMode EXACT
All number expressions are treated as infinite-precision numbers. This follows the spirit of YANG 1.1 -- where mostly have integral types and decimal64 mapped to BigDecimal. Non-decimal numbers are mapped either toint
,long
orBigInteger
.
-
-
Method Detail
-
values
public static YangXPathMathMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (YangXPathMathMode c : YangXPathMathMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static YangXPathMathMode valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getSupport
public YangXPathMathSupport getSupport()
ReturnYangXPathMathSupport
which provides support for the this mode.- Returns:
- YangXPathMathSupport supporting this mode.
-
-