Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ChunkedFileUploader

Breaks files into manageable chunks for upload.

Hierarchy

  • ChunkedFileUploader

Index

Constructors

constructor

  • Parameters

    • V: Vasat
    • url: string
    • Default value chunkSize: number = 1000000

    Returns ChunkedFileUploader

Properties

Private V

V: Vasat

cnx

cnx: boolean

currentXHR

currentXHR: XMLHttpRequest

fileRef

fileRef: File

loaded

loaded: number

progress

progress: number

progressObservable

progressObservable: any = this.progressSubject.asObservable()

progressSubject

progressSubject: Subject<number> = new Subject()

start

start: number

step

step: number = 5000000

total

total: number

Private url

url: string

Methods

cancel

  • cancel(): void
  • Cancels the current XMLHttpRequest.

    Returns void

uploadObservable

  • uploadObservable(file: any, startOffset?: number, seqOffset?: number): any
  • Uploads the a file by fragmenting it to smaller pieces depending on the given parameters.

    Parameters

    • file: any

      File to upload.

    • Optional startOffset: number

      Start of offset.

    • Optional seqOffset: number

      The sequence number, where 0 is first.

    Returns any

Generated using TypeDoc