Packages

sealed abstract class Number[T <: Number[T]] extends NetworkElement with Ordered[T] with BasicArithmetic[T]

This abstract class is meant to represent a signed and unsigned number in C This is useful for dealing with codebases/protocols that rely on C's unsigned integer types

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Number
  2. BasicArithmetic
  3. Ordered
  4. Comparable
  5. NetworkElement
  6. AnyRef
  7. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. type A = BigInt

Abstract Value Members

  1. abstract def andMask: BigInt

    This is used to determine the valid amount of bytes in a number for instance a UInt8 has an andMask of 0xff a UInt32 has an andMask of 0xffffffff

  2. abstract def apply: (A) => T

    Factory function to create the underlying T, for instance a UInt32.

    Factory function to create the underlying T, for instance a UInt32. This method must check if the parameter is in the required range.

  3. abstract def underlying: A

    The underlying scala number used to to hold the number

    The underlying scala number used to to hold the number

    Attributes
    protected

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. def &(num: T): T
  4. def *(num: T): T
    Definition Classes
    NumberBasicArithmetic
  5. def *(factor: BigInt): T
    Definition Classes
    NumberBasicArithmetic
  6. def +(num: T): T
    Definition Classes
    NumberBasicArithmetic
  7. def -(num: T): T
    Definition Classes
    NumberBasicArithmetic
  8. def <(that: T): Boolean
    Definition Classes
    Ordered
  9. def <<(num: T): T
  10. def <<(num: Int): T
  11. def <=(that: T): Boolean
    Definition Classes
    Ordered
  12. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  13. def >(that: T): Boolean
    Definition Classes
    Ordered
  14. def >=(that: T): Boolean
    Definition Classes
    Ordered
  15. def >>(num: T): T
  16. def >>(num: Int): T
  17. def addSafe(n: T): Try[T]

    Some classes have restrictions on upper bounds for it's underlying value.

    Some classes have restrictions on upper bounds for it's underlying value. This might cause the + operator to throw. This method wraps it in a Try block.

    Definition Classes
    BasicArithmetic
  18. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  19. def bytes: ByteVector

    The byte representation of the NetworkElement

    The byte representation of the NetworkElement

    Definition Classes
    NumberNetworkElement
  20. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  21. def compare(num: T): Int
    Definition Classes
    Number → Ordered
  22. def compareTo(that: T): Int
    Definition Classes
    Ordered → Comparable
  23. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  24. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  25. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  26. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  27. def hex: String

    The hexadecimal representation of the NetworkElement

    The hexadecimal representation of the NetworkElement

    Definition Classes
    NetworkElement
  28. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  29. def logger: Logger
    Definition Classes
    NetworkElement
  30. def multiplySafe(factor: T): Try[T]

    Some classes have restrictions on upper bounds for it's underlying value.

    Some classes have restrictions on upper bounds for it's underlying value. This might cause the * operator to throw. This method wraps it in a Try block.

    Definition Classes
    BasicArithmetic
  31. def multiplySafe(factor: BigInt): Try[T]

    Some classes have restrictions on upper bounds for it's underlying value.

    Some classes have restrictions on upper bounds for it's underlying value. This might cause the * operator to throw. This method wraps it in a Try block.

    Definition Classes
    BasicArithmetic
  32. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  33. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  34. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  35. def size: Long

    The size of the NetworkElement in bytes.

    The size of the NetworkElement in bytes.

    Definition Classes
    NetworkElement
  36. def subtractSafe(n: T): Try[T]

    Some classes have restrictions on lower bounds for it's underlying value.

    Some classes have restrictions on lower bounds for it's underlying value. This might cause the - operator to throw. This method wraps it in a Try block.

    Definition Classes
    BasicArithmetic
  37. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  38. def toBigInt: BigInt
  39. def toInt: Int
  40. def toLong: Long
  41. def toString(): String
    Definition Classes
    AnyRef → Any
  42. def unary_-: T
  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. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  46. def |(num: T): T

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated @deprecated
    Deprecated

    (Since version ) see corresponding Javadoc for more information.

Inherited from BasicArithmetic[T]

Inherited from Ordered[T]

Inherited from Comparable[T]

Inherited from NetworkElement

Inherited from AnyRef

Inherited from Any

Ungrouped