メインコンテンツへスキップ

abstractResource <T>

Hierarchy

Index

Constructors

constructor

  • Type parameters

    • T: File | Directory

    Returns Resource<T>

Accessors

isAsync

  • get isAsync(): boolean
  • Whether this Resource is loaded asynchronously


    Returns boolean

abstractname

  • get name(): string
  • The name of the referenced file


    Returns string

progress

Methods

abstractresolve

  • resolve(): Promise<T>
  • Returns Promise<T>

setPlayground

  • setPlayground(playground: UniversalPHP): void
  • Parameters

    • playground: UniversalPHP

    Returns void

staticcreate

  • Creates a new Resource based on the given file reference


    Parameters

    • ref: FileReference | DirectoryReference

      The file reference to create the Resource for

    • options: { corsProxy?: string; progress?: ProgressTracker; semaphore?: default; streamBundledFile?: StreamBundledFile }

      Additional options for the Resource

      • optionalcorsProxy: string
      • optionalprogress: ProgressTracker
      • optionalsemaphore: default

        Optional semaphore to limit concurrent downloads

      • optionalstreamBundledFile: StreamBundledFile

    Returns Resource<File | Directory>

    A new Resource instance