@nebius/js-sdk - v0.2.54
    Preparing search index...

    Interface MessageFns<T, TType>

    Defines the static runtime operations emitted for a generated message.

    Generated message exports implement this interface. Application code normally uses create for type-safe construction, encode followed by finish() for wire bytes, and decode for wire input.

    interface MessageFns<T, TType extends string> {
        $descriptor?: MessageDescriptor;
        $type: TType;
        create<
            I extends
                | string
                | number
                | boolean
                | Function
                | Date
                | Uint8Array<ArrayBufferLike>
                | Long
                | Partial<unknown>[]
                | readonly Partial<unknown>[]
                | { [K in string | number | symbol]?: DeepPartial<T[K]> }
                | Partial<T>
                | undefined,
        >(
            base?: I,
        ): T;
        decode(
            input: Uint8Array<ArrayBufferLike> | BinaryReader,
            length?: number,
        ): T;
        encode(message: T, writer?: BinaryWriter): BinaryWriter;
        fromJSON(object: any): T;
        fromPartial<
            I extends
                | string
                | number
                | boolean
                | Function
                | Date
                | Uint8Array<ArrayBufferLike>
                | Long
                | Partial<unknown>[]
                | readonly Partial<unknown>[]
                | { [K in string | number | symbol]?: DeepPartial<T[K]> }
                | Partial<T>
                | undefined,
        >(
            object: I,
        ): T;
        toJSON(message: T, use?: "json" | "pb"): unknown;
    }

    Type Parameters

    • T
    • TType extends string
    Index
    $descriptor?: MessageDescriptor

    Contains optional reflection data used by SDK runtime helpers.

    $type: TType

    Contains the fully qualified runtime type name.

    • Creates a message from a deep partial value and applies field defaults.

      Type Parameters

      • I extends
            | string
            | number
            | boolean
            | Function
            | Date
            | Uint8Array<ArrayBufferLike>
            | Long
            | Partial<unknown>[]
            | readonly Partial<unknown>[]
            | { [K in string | number | symbol]?: DeepPartial<T[K]> }
            | Partial<T>
            | undefined

      Parameters

      • Optionalbase: I

      Returns T

    • Decodes one message from wire bytes or a reader.

      Parameters

      • input: Uint8Array<ArrayBufferLike> | BinaryReader
      • Optionallength: number

      Returns T

    • Encodes a message into a supplied or new protobuf writer.

      Parameters

      • message: T
      • Optionalwriter: BinaryWriter

      Returns BinaryWriter

    • Converts protobuf JSON input to the generated TypeScript representation.

      Parameters

      • object: any

      Returns T

    • Converts a deep partial value to a complete generated message.

      Type Parameters

      • I extends
            | string
            | number
            | boolean
            | Function
            | Date
            | Uint8Array<ArrayBufferLike>
            | Long
            | Partial<unknown>[]
            | readonly Partial<unknown>[]
            | { [K in string | number | symbol]?: DeepPartial<T[K]> }
            | Partial<T>
            | undefined

      Parameters

      • object: I

      Returns T

    • Converts a message to JSON.

      json uses standard protobuf JSON forms. pb exposes protobuf field shapes for SDK compatibility where supported.

      Parameters

      • message: T
      • Optionaluse: "json" | "pb"

      Returns unknown