UnitInterval

scalus.cardano.ledger.UnitInterval
See theUnitInterval companion class
object UnitInterval

Attributes

Companion
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type

Members list

Type members

Inherited and Abstract types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def fromDouble(value: Double): UnitInterval

Creates a UnitInterval from a double value. Uses a precision of 1,000,000 for the conversion.

Creates a UnitInterval from a double value. Uses a precision of 1,000,000 for the conversion.

Value parameters

value

A double between 0 and 1

Attributes

Returns

The corresponding UnitInterval

Concrete fields

A predefined UnitInterval representing 0.5 (1/2).

A predefined UnitInterval representing 0.5 (1/2).

Attributes

A predefined UnitInterval representing 1 (1/1).

A predefined UnitInterval representing 1 (1/1).

Attributes

A predefined UnitInterval representing 0 (0/1).

A predefined UnitInterval representing 0 (0/1).

Attributes

Givens

Givens

CBOR Decoder for UnitInterval. Decodes from a tagged array [numerator, denominator] with tag 30.

CBOR Decoder for UnitInterval. Decodes from a tagged array [numerator, denominator] with tag 30.

Attributes

CBOR Encoder for UnitInterval. Encodes as a tagged array [numerator, denominator] with tag 30.

CBOR Encoder for UnitInterval. Encodes as a tagged array [numerator, denominator] with tag 30.

Attributes