Hierarchy

Constructors

Properties

RPC_TYPE_ID: string

Should be set to a constant specifying the SharedObject type identifier on the prototype of final derived owner classes. It is not used on counterpart (non-owner) classes.

chunkManager: ChunkManager
chunks: Map<string, Chunk> = ...
credentialsProvider: undefined | CredentialsProvider<any>
disposedStacks: any
freeChunks: Chunk[] = ...
isOwner: undefined | boolean
refCount: number = 1
referencedGeneration: number
rpc: null | RPC = null
rpcId: null | number = null
sourceQueueLevel: number = 0

sourceQueueLevel must be greater than the sourceQueueLevel of any ChunkSource whose download method depends on chunks from this source. A normal ChunkSource with no other dependencies should have a level of 0.

statistics: Float64Array = ...
unreferencedGeneration: number
wasDisposed: undefined | boolean

Methods

  • Adds the specified chunk to the chunk cache.

    If the chunk cache was previously empty, also call this.addRef() to increment the reference count.

    Parameters

    Returns void

  • Precondition: this.isOwner === true.

    Returns {
        gen: number;
        id: null | number;
    }

    • gen: number
    • id: null | number
  • Precondition: this.isOwner === true.

    This should be called when the counterpart's refCount is decremented and reaches zero.

    Parameters

    • generation: number

    Returns void

  • Returns void

  • Returns void

  • Parameters

    • rpc: RPC
    • options: any = {}

    Returns void

  • Parameters

    • rpc: RPC
    • rpcId: number = ...

    Returns void

  • Precondition: this.isOwner === true.

    Returns void

  • Returns void

  • Type Parameters

    • T extends {
          cancel: (() => void);
      }

    Parameters

    • cancellable: T

    Returns T

  • Type Parameters

    Parameters

    • f: T

    Returns T

  • Remove the specified chunk from the chunk cache.

    If the chunk cache becomes empty, also call this.dispose() to decrement the reference count.

    Parameters

    Returns void

  • Type Parameters

    Parameters

    • f: T

    Returns T

Generated using TypeDoc