Class

sigma.ast.syntax

ValueOps

Related Doc: package syntax

Permalink

implicit final class ValueOps extends AnyVal

Type casting methods for Value nodes. Each asX method casts the value to the corresponding X type of node. No runtime checks are performed, so the caller should ensure that the value has the expected type.

Linear Supertypes
AnyVal, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ValueOps
  2. AnyVal
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ValueOps(v: Value[SType])

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  4. def asBigInt: Value[SBigInt.type]

    Permalink
  5. def asBoolValue: Value[SBoolean.type]

    Permalink
  6. def asBox: Value[SBox.type]

    Permalink
  7. def asByteArray: Value[SByteArray]

    Permalink
  8. def asByteValue: Value[SByte.type]

    Permalink
  9. def asCollection[T <: SType]: Value[SCollection[T]]

    Permalink
  10. def asFunc: Value[SFunc]

    Permalink
  11. def asGroupElement: Value[SGroupElement.type]

    Permalink
  12. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  13. def asIntArray: Value[SIntArray]

    Permalink
  14. def asIntValue: Value[SInt.type]

    Permalink
  15. def asNumValue: Value[SNumericType]

    Permalink
  16. def asOption[T <: SType]: Value[SOption[T]]

    Permalink
  17. def asSigmaProp: Value[SSigmaProp.type]

    Permalink
  18. def asTuple: Value[STuple]

    Permalink
  19. def asValue[T <: SType]: Value[T]

    Permalink
  20. def getClass(): Class[_ <: AnyVal]

    Permalink
    Definition Classes
    AnyVal → Any
  21. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  22. def toString(): String

    Permalink
    Definition Classes
    Any
  23. def upcastTo[T <: SNumericType](targetType: T): Value[T]

    Permalink

    Upcast the value v to the given type checking that v if of a numeric type.

    Upcast the value v to the given type checking that v if of a numeric type.

    targetType

    type to upcast to

    returns

    upcasted value

  24. val v: Value[SType]

    Permalink
  25. def withEnsuredSrcCtx[T <: SType](sourceContext: Nullable[SourceContext]): Value[T]

    Permalink

    Sets the source context of the v instance only if it's empty (i.e.

    Sets the source context of the v instance only if it's empty (i.e. not set yet).

  26. def withPropagatedSrcCtx[T <: SType](srcCtx: Nullable[SourceContext]): Value[T]

    Permalink

    Set source context to all nodes missing source context in the given tree.

    Set source context to all nodes missing source context in the given tree.

    srcCtx

    source context to set

    returns

    AST where all nodes with missing source context are set to the given srcCtx

  27. def withSrcCtx[T <: SType](sourceContext: Nullable[SourceContext]): Value[T]

    Permalink

    Assigns optional SourceContext to the value v.

    Assigns optional SourceContext to the value v. The is effectful operation changing state of v.

    returns

    the same instance of v with the given source context assigned

Inherited from AnyVal

Inherited from Any

Ungrouped