Hierarchy (view full)

Constructors

  • Parameters

    • filename: string
    • type: string
    • size: number
    • sampleRate: number
    • durationSamples: number
    • channels: number
    • bitrate: number
    • OptionalaudioBufferInfo: {
          sampleRate: number;
          samples: number;
      }
      • sampleRate: number
      • samples: number

    Returns AudioInfo

Properties

_audioBufferInfo?: {
    sampleRate: number;
    samples: number;
}
_extension: string
_file: undefined | File
_hash?: string
_name: string
_size: number
_type: string
_url?: string

Accessors

  • get audioBufferInfo(): undefined | {
        sampleRate: number;
        samples: number;
    }
  • Returns undefined | {
        sampleRate: number;
        samples: number;
    }

  • set audioBufferInfo(value): void
  • Parameters

    • value: undefined | {
          sampleRate: number;
          samples: number;
      }

    Returns void

  • get available(): boolean
  • returns if the file is ready for processing

    Returns boolean

  • get extension(): string
  • extension including the dot. (this must contain a dot!)

    Returns string

  • get hash(): undefined | string
  • Returns undefined | string

  • set hash(value): void
  • Parameters

    • value: undefined | string

    Returns void

Methods

  • Parameters

    • fullname: string

    Returns {
        extension: string;
        name: string;
    }

    • extension: string
    • name: string
  • creates a FileInfo instance form a URL. It doesn't contain the file itself.

    Parameters

    • url: string
    • Optionaltype: string
    • Optionalname: string
    • createdAt: number = 0
    • Optionalsize: number

    Returns FileInfo

  • Parameters

    • extension: string

    Returns
        | "audio/wav"
        | "audio/mpeg"
        | "audio/ogg"
        | "audio/opus"
        | "video/mp4"
        | "image/png"
        | "image/jpg"
        | "application/pdf"
        | "application/json"
        | "text/plain"