Options
All
  • Public
  • Public/Protected
  • All
Menu

Class SigaaHTTPSession

Hierarchy

  • SigaaHTTPSession

Implements

Index

Constructors

constructor

Properties

Private requestPromises

requestPromises: RequestPromiseTracker[] = []

url

url: string

Accessors

requestStacks

Methods

afterDownloadRequest

  • afterDownloadRequest(url: URL, downloadPath: string, sessionHttpOptions: HTTPRequestOptions, finalPath: string): Promise<string>

afterHTTPOptions

afterSuccessfulRequest

afterUnsuccessfulRequest

  • afterUnsuccessfulRequest(err: Error, httpOptions: HTTPRequestOptions, body?: string | Buffer): Promise<Page>

beforeDownloadRequest

  • beforeDownloadRequest(): Promise<null>

beforeRequest

  • It is called before the request, it may be useful to delay. If you return a page, the answer will be the page and there will be no http request If it returns null, the request will continue as normal and if you want to suspend the request, it may generate an error.

    Parameters

    Returns Promise<null | Page>

close

  • close(): void

Private findAndRemovePromiseRequest

getURL

  • getURL(path: string): URL

Generated using TypeDoc