Strophe.js
    Preparing search index...

    Class Request

    Helper class that provides a cross implementation abstraction for a BOSH related XMLHttpRequest.

    The Request class is used internally to encapsulate BOSH request information. It is not meant to be used from user's code.

    Index
    • Create and initialize a new Request object.

      Parameters

      • elem: Element

        The XML data to be sent in the request.

      • func: (req: Request) => void

        The function that will be called when the XMLHttpRequest readyState changes.

      • rid: number

        The BOSH rid attribute associated with this request.

      • sends: number = 0

        The number of times this same request has been sent.

      Returns Request

    abort: boolean
    age: () => number
    data: string
    date: number
    dead: Date
    func: (req: Request) => void
    id: number
    origFunc: (req: Request) => void
    rid: number
    sends: number
    timeDead: () => number
    xhr: XMLHttpRequest
    xmlData: Element
    • Get a response from the underlying XMLHttpRequest. This function attempts to get a response from the request and checks for errors.

      Returns Element

      The DOM element tree of the response.

      "parsererror" - A parser error occured.

      "bad-format" - The entity has sent XML that cannot be processed.