/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
import { Bytes } from "#general";
import { BitField, BitFlag, Schema, TypeFromPartialBitSchema } from "#types";
export declare const BDX_VERSION = 0;
/**
 * BDX Transfer protocol bitmap definition
 * Bit 7 is reserved for future use
 *
 * @see {@link MatterSpecification.v141.Core}, section 11.22.5.1
 */
export declare const BdxTransferControlBitmap: {
    /** Protocol Version, Only allowed version is 0.0 for now */
    version: BitField;
    /** Indicates if Sender drive is supported by Initiator */
    senderDrive: BitFlag;
    /** Indicates if Receiver drive is supported by Initiator */
    receiverDrive: BitFlag;
    /**
     * Indicates if Asynchronous Transfer is supported by Initiator
     * Synchronous mode is always implicitly supported.
     */
    asynchronousTransfer: BitFlag;
};
export declare const BdxTransferControlSchema: import("#types").BitmapSchemaInternal<{
    /** Protocol Version, Only allowed version is 0.0 for now */
    version: BitField;
    /** Indicates if Sender drive is supported by Initiator */
    senderDrive: BitFlag;
    /** Indicates if Receiver drive is supported by Initiator */
    receiverDrive: BitFlag;
    /**
     * Indicates if Asynchronous Transfer is supported by Initiator
     * Synchronous mode is always implicitly supported.
     */
    asynchronousTransfer: BitFlag;
}>;
/**
 * BDX Range control bitmap definition
 * Bits 2-3 and 5-7 is reserved for future use
 *
 * @see {@link MatterSpecification.v141.Core}, section 11.22.5.1
 */
export declare const BdxRangeControlBitmap: {
    /** Indicates if the transfer has a definite length */
    definiteLength: BitFlag;
    /** Indicates if the transfer has a start offset */
    startOffset: BitFlag;
    /**
     * Indicates if wide (64-bit) range enabled for values
     * Offset (STARTFOFS) and length (DEFLEN) are 4 octets (32-bit) little-endian unsigned quantities.
     */
    wideRange: BitFlag;
};
export declare const BdxRangeControlSchema: import("#types").BitmapSchemaInternal<{
    /** Indicates if the transfer has a definite length */
    definiteLength: BitFlag;
    /** Indicates if the transfer has a start offset */
    startOffset: BitFlag;
    /**
     * Indicates if wide (64-bit) range enabled for values
     * Offset (STARTFOFS) and length (DEFLEN) are 4 octets (32-bit) little-endian unsigned quantities.
     */
    wideRange: BitFlag;
}>;
/** @see {@link MatterSpecification.v141.Core}, section 11.22.5.1 */
export type BdxInit = {
    /**
     * Transfer protocol details
     * PTC
     * 1 octet
     */
    transferProtocol: TypeFromPartialBitSchema<typeof BdxTransferControlBitmap>;
    /**
     * Range Control details - Removed because it is used by encoding/decoding implicitly
     * RTC, 1 octet
     */
    /**
     * Specifies the maximum data size (in bytes) of the block that the Initiator supports, exclusive of block header
     * fields, such as a block counter.
     * PMBS, 2 octets
     */
    maxBlockSize: number;
    /**
     * Optional 32-bit/64-bit length that specifies the offset in bytes from start of the file from which the Sender
     * would start the transfer.
     * STARTOFS, 4/8 octets
     */
    startOffset?: number | bigint;
    /**
     * Specifies a predetermined definite length for the transfer
     * DEFLEN, 4/8 octets
     */
    maxLength?: number | bigint;
    /**
     * Identifier chosen by the Initiator to identify the payload to be transferred.
     * FD, 2 octets + Variable length
     */
    fileDesignator: Bytes;
    /**
     * Allows the Initiator to send additional application-specific information about the file to be transferred
     * MD, Variable length, TLV
     */
    metaData?: Bytes;
};
/** Schema for BDX SendInit and ReceiveInit messages. */
export declare class BdxInitMessageSchema extends Schema<BdxInit> {
    encodeInternal(message: BdxInit): Uint8Array<ArrayBufferLike>;
    decodeInternal(bytes: Bytes): BdxInit;
    validate({ transferProtocol, maxBlockSize, fileDesignator }: BdxInit): void;
}
export declare const BdxSendInitMessage: BdxInitMessageSchema;
export declare const BdxReceiveInitMessage: BdxInitMessageSchema;
//# sourceMappingURL=BdxInitMessagesSchema.d.ts.map