import { BitSchema, TypeFromPartialBitSchema } from "../schema/BitmapSchema.js";
import { TlvLength, TlvTag, TlvType, TlvTypeLength } from "./TlvCodec.js";
import { TlvReader, TlvSchema, TlvWriter } from "./TlvSchema.js";
import { TlvWrapper } from "./TlvWrapper.js";
/**
 * Schema to encode an unsigned integer in TLV.
 *
 * @see {@link MatterSpecification.v10.Core} § A.11.1
 */
export declare class TlvNumericSchema<T extends bigint | number> extends TlvSchema<T> {
    #private;
    readonly type: TlvType.UnsignedInt | TlvType.SignedInt | TlvType.Float;
    protected readonly lengthProvider: (value: T) => TlvLength;
    readonly baseTypeMin: T;
    readonly baseTypeMax: T;
    constructor(type: TlvType.UnsignedInt | TlvType.SignedInt | TlvType.Float, lengthProvider: (value: T) => TlvLength, baseTypeMin: T, baseTypeMax: T, min?: T, max?: T);
    get min(): T;
    get max(): T;
    encodeTlvInternal(writer: TlvWriter, value: T, tag?: TlvTag): void;
    decodeTlvInternalValue(reader: TlvReader, typeLength: TlvTypeLength): T;
    validate(value: T): void;
    validateBoundaries(value: T): void;
    /** Restrict value range. */
    bound({ min, max }: NumericConstraints<T>): TlvNumericSchema<T>;
}
export type NumericConstraints<T extends number | bigint = number | bigint> = {
    min?: T;
    max?: T;
};
export declare class TlvNumberSchema extends TlvNumericSchema<number> {
    constructor(type: TlvType.UnsignedInt | TlvType.SignedInt | TlvType.Float, lengthProvider: (value: number) => TlvLength, baseTypeMin: number, baseTypeMax: number, min?: number, max?: number);
    decodeTlvInternalValue(reader: TlvReader, typeLength: TlvTypeLength): number;
    bound({ min, max }: NumericConstraints<number>): TlvNumericSchema<number>;
    validate(value: number): void;
}
export declare const TlvLongNumberSchema: {
    new (type: TlvType.UnsignedInt | TlvType.SignedInt | TlvType.Float, lengthProvider: (value: number | bigint) => TlvLength, baseTypeMin: number | bigint, baseTypeMax: number | bigint, min?: number | bigint | undefined, max?: number | bigint | undefined): TlvNumericSchema<number | bigint>;
};
/** Unsigned integer TLV schema. */
export declare const TlvFloat: TlvNumberSchema;
export declare const TlvDouble: TlvNumberSchema;
export declare const TlvInt8: TlvNumberSchema;
export declare const TlvInt16: TlvNumberSchema;
export declare const TlvInt32: TlvNumberSchema;
export declare const TlvInt64: TlvNumericSchema<number | bigint>;
export declare const TlvUInt8: TlvNumberSchema;
export declare const TlvUInt16: TlvNumberSchema;
export declare const TlvUInt24: TlvNumberSchema;
export declare const TlvUInt32: TlvNumberSchema;
export declare const TlvUInt64: TlvNumericSchema<number | bigint>;
export declare const TlvEnum: <T>() => TlvSchema<T>;
export declare const TlvBitmap: <T extends BitSchema>(underlyingSchema: TlvNumberSchema, bitSchema: T) => TlvWrapper<TypeFromPartialBitSchema<T>, number>;
export declare const TlvPercent: TlvNumericSchema<number>;
export declare const TlvPercent100ths: TlvNumericSchema<number>;
export declare const TlvPosixMs: TlvNumericSchema<number | bigint>;
export declare const TlvSysTimeUs: TlvNumericSchema<number | bigint>;
export declare const TlvSysTimeMS: TlvNumericSchema<number | bigint>;
/** Milliseconds from Unix epoch (1970-01-01) to Matter epoch (2000-01-01) */
export declare const MATTER_EPOCH_OFFSET: import("#general").Duration;
/** Seconds from Unix epoch (1970-01-01) to Matter epoch (2000-01-01) */
export declare const MATTER_EPOCH_OFFSET_S: number;
/** Microseconds from Unix epoch (1970-01-01) to Matter epoch (2000-01-01) */
export declare const MATTER_EPOCH_OFFSET_US: bigint;
/**
 * TLV Schema for Epoch time in seconds since Matter epoch (2000-01-01). You can just use the normal unix epoch
 * time (since 1970-01-01) number and it will be converted automatically.
 */
export declare const TlvEpochS: TlvWrapper<number, number>;
/**
 * TLV Schema for Epoch time in microseconds since Matter epoch (2000-01-01). You can just use the unix epoch as
 * microseconds (since 1970-01-01) number and it will be converted automatically.
 */
export declare const TlvEpochUs: TlvWrapper<number | bigint, number | bigint>;
//# sourceMappingURL=TlvNumber.d.ts.map