Packages

object ErgoTree extends Serializable

Linear Supertypes
Serializable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ErgoTree
  2. Serializable
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. type HeaderType = Byte with Tag[Byte, ErgoTree.HeaderType.Tag]

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. val ConstantSegregationFlag: Byte

    Header flag to indicate that constant segregation should be applied.

  5. val ConstantSegregationHeader: HeaderType

    Default header with constant segregation enabled.

  6. val DefaultHeader: HeaderType

    Default value of ErgoTree.header byte

  7. val EmptyConstants: IndexedSeq[Constant[SType]]
  8. val SizeFlag: Byte

    Header flag to indicate that whole size of ErgoTree should be saved before tree content.

  9. val VersionFlag: Byte

    Current version of ErgoTree serialization format (aka bite-code language version)

  10. val VersionMask: Byte

    Header mask to extract version bits.

  11. val ZeroHeader: HeaderType

    Header with all the flags set to 0 and version 0.

  12. def apply(header: HeaderType, constants: IndexedSeq[Constant[SType]], root: SigmaPropValue): ErgoTree

    Create an ErgoTree with the given parameters.

  13. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  14. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  15. final def defaultHeaderWithVersion(version: Byte): HeaderType

    Creates valid header byte with the given version.

    Creates valid header byte with the given version. The SizeFlag is set if version > 0

    Annotations
    @inline()
  16. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  17. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  18. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  19. def fromBytes(bytes: Array[Byte]): ErgoTree

    Deserializes an ErgoTree instance from an array of bytes.

    Deserializes an ErgoTree instance from an array of bytes.

    bytes

    an array of bytes representing the serialized ErgoTree

  20. def fromHex(hex: String): ErgoTree

    Deserializes an ErgoTree instance from a hexadecimal string.

    Deserializes an ErgoTree instance from a hexadecimal string.

    hex

    a hexadecimal string representing the serialized ErgoTree

  21. def fromProposition(header: HeaderType, prop: SigmaPropValue): ErgoTree

    Create new ErgoTree for the given proposition using the given header flags.

    Create new ErgoTree for the given proposition using the given header flags. If the property is not a simple constant, then constant segregation is performed.

  22. def fromProposition(prop: SigmaPropValue): ErgoTree

    Create new ErgoTree for the given proposition using default header.

    Create new ErgoTree for the given proposition using default header. If the property is not a simple constant, then constant segregation is performed.

  23. def fromSigmaBoolean(header: HeaderType, pk: SigmaBoolean): ErgoTree

    Create new ErgoTree for the given sigma proposition using the given header flags and without performing constant segregation.

  24. def fromSigmaBoolean(pk: SigmaBoolean): ErgoTree

    Create new ErgoTree for the given sigma proposition using default header and without performing constant segregation.

  25. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  26. final def getVersion(header: HeaderType): Byte

    returns

    a value of the version bits from the given header byte.

    Annotations
    @inline()
  27. final def hasSize(header: HeaderType): Boolean

    returns

    true if the size flag is set to 1 in the given header byte.

    Annotations
    @inline()
  28. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  29. final def headerWithVersion(header: HeaderType, version: Byte): HeaderType

    Creates valid header byte with the given version.

    Creates valid header byte with the given version. The SizeFlag is set if version > 0

    Annotations
    @inline()
  30. final def isConstantSegregation(header: HeaderType): Boolean

    returns

    true if the constant segregation flag is set to 1 in the given header byte.

    Annotations
    @inline()
  31. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  32. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  33. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  34. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  35. final def setConstantSegregation(header: HeaderType): HeaderType

    Sets the ConstantSegregationFlag in the given header

    Sets the ConstantSegregationFlag in the given header

    Annotations
    @inline()
  36. final def setRequiredBits(header: HeaderType): HeaderType

    Sets the required bit in the given header: - The SizeFlag is set if version > 0

    Sets the required bit in the given header: - The SizeFlag is set if version > 0

    Annotations
    @inline()
  37. final def setSizeBit(header: HeaderType): HeaderType

    Sets the ConstantSegregationFlag in the given header

    Sets the ConstantSegregationFlag in the given header

    Annotations
    @inline()
  38. final def setVersionBits(header: HeaderType, version: Byte): HeaderType

    Update the version bits of the given header byte with the given version value, leaving all other bits unchanged.

    Update the version bits of the given header byte with the given version value, leaving all other bits unchanged.

    Annotations
    @inline()
  39. def substConstants(root: SValue, constants: IndexedSeq[Constant[SType]]): SValue

    Substitute ConstantPlaceholder nodes in the given expression with the constants taken from the given collection.

    Substitute ConstantPlaceholder nodes in the given expression with the constants taken from the given collection.

    root

    expression to transform

    constants

    collection of constants to replace placeholders

    returns

    new expression without placeholders

  40. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  41. def toString(): String
    Definition Classes
    AnyRef → Any
  42. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  43. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  44. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  45. def withSegregation(header: HeaderType, prop: SigmaPropValue): ErgoTree

    Build ErgoTree via serialization of the value with ConstantSegregationHeader, constants segregated from the tree and ConstantPlaceholders referring to the segregated constants.

    Build ErgoTree via serialization of the value with ConstantSegregationHeader, constants segregated from the tree and ConstantPlaceholders referring to the segregated constants.

    This method uses single traverse of the tree to: 1) find and segregate all constants; 2) replace constants with ConstantPlaceholders in the tree; 3) write the tree to the Writer's buffer obtaining treeBytes; 4) deserialize tree with ConstantPlaceholders.

    prop

    expression to be transformed into ErgoTree

  46. def withoutSegregation(header: HeaderType, root: SigmaPropValue): ErgoTree

    Create new ErgoTree for the given proposition using the given header flags and without performing constant segregation.

  47. object HeaderType extends TaggedType[Byte]

    Represents information in ErgoTree header.

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped