Evolution SDK

EpochNo.ts

EpochNo overview


Table of contents


generators

generator

Generate a random EpochNo.

Signature

export declare const generator: Arbitrary<bigint>

Added in v2.0.0

model

EpochNo (type alias)

Type alias for EpochNo representing blockchain epoch numbers.

Signature

export type EpochNo = typeof EpochNoSchema.Type

Added in v2.0.0

ordering

compare

Compare two EpochNo values.

Signature

export declare const compare: (a: EpochNo, b: EpochNo) => -1 | 0 | 1

Added in v2.0.0

predicates

is

Check if a value is a valid EpochNo.

Signature

export declare const is: (u: unknown, overrideOptions?: ParseOptions | number) => u is bigint

Added in v2.0.0

schemas

EpochNoSchema

Schema for validating epoch numbers (0-255).

Signature

export declare const EpochNoSchema: Schema.refine<bigint, typeof Schema.BigInt>

Added in v2.0.0

utils

CDDLSchema

CDDL schema bridge for epoch_no = uint .size 8

Signature

export declare const CDDLSchema: typeof Schema.BigIntFromSelf

FromCDDL

Signature

export declare const FromCDDL: Schema.transform<typeof Schema.BigIntFromSelf, Schema.SchemaClass<bigint, bigint, never>>

arbitrary

Signature

export declare const arbitrary: Arbitrary<bigint>