Documentation - v0.27.1
    Preparing search index...

    Class StubMemoryTelegramStorage

    In-memory storage driver implementation for mtcute.

    This storage is not persistent, meaning that all data will be lost on restart. Only use this storage for testing, or if you know exactly what you're doing.

    Hierarchy (View Summary)

    Index

    Constructors

    • Parameters

      • params: { hasKeys?: boolean | number[]; hasTempKeys?: boolean | number[] } = ...
        • OptionalhasKeys?: boolean | number[]

          IDs of the DCs for which the storage should have auth keys, or true to have keys for all DCs

          true
          
        • OptionalhasTempKeys?: boolean | number[]

          IDs of the DCs for which the storage should have temp auth keys, or true to have keys for all DCs

          true
          

      Returns StubMemoryTelegramStorage

    Properties

    authKeys: MemoryAuthKeysRepository = ...
    driver: MemoryStorageDriver = ...
    params: { hasKeys?: boolean | number[]; hasTempKeys?: boolean | number[] } = ...

    Type Declaration

    • OptionalhasKeys?: boolean | number[]

      IDs of the DCs for which the storage should have auth keys, or true to have keys for all DCs

      true
      
    • OptionalhasTempKeys?: boolean | number[]

      IDs of the DCs for which the storage should have temp auth keys, or true to have keys for all DCs

      true
      
    refMessages: MemoryRefMessagesRepository = ...

    Methods

    • Parameters

      • crypto: ICryptoProvider
      • data: Uint8Array
      • dcId: number
      • OptionaltempIndex: number

      Returns Uint8Array