Class

io.scalajs.nodejs.http

ServerEvents

Related Doc: package http

Permalink

implicit final class ServerEvents extends AnyVal

Server Events

Linear Supertypes
AnyVal, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ServerEvents
  2. AnyVal
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ServerEvents(server: Server)

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def closeFuture(): Promise[Unit]

    Permalink
    Annotations
    @inline()
  6. def getClass(): Class[_ <: AnyVal]

    Permalink
    Definition Classes
    AnyVal → Any
  7. def getConnectionsFuture: Promise[Int]

    Permalink
    Annotations
    @inline()
  8. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  9. def listenFuture(options: ListenerOptions): Promise[Unit]

    Permalink
    Annotations
    @inline()
  10. def onCheckContinue(callback: (ClientRequest, ServerResponse) ⇒ Any): server.type

    Permalink

    Emitted each time a request with an http Expect: 100-continue is received.

    Emitted each time a request with an http Expect: 100-continue is received. If this event isn't listened for, the server will automatically respond with a 100 Continue as appropriate.

    Handling this event involves calling response.writeContinue() if the client should continue to send the request body, or generating an appropriate HTTP response (e.g., 400 Bad Request) if the client should not continue to send the request body.

    Note that when this event is emitted and handled, the 'request' event will not be emitted.

    Annotations
    @inline()
    Example:
    1. server.on("checkContinue", function (request, response) { ... })

  11. def onClientError(callback: (SystemError, Socket) ⇒ Any): server.type

    Permalink

    If a client connection emits an 'error' event, it will be forwarded here.

    If a client connection emits an 'error' event, it will be forwarded here. Listener of this event is responsible for closing/destroying the underlying socket. For example, one may wish to more gracefully close the socket with an HTTP '400 Bad Request' response instead of abruptly severing the connection.

    Default behavior is to destroy the socket immediately on malformed request.

    socket is the net.Socket object that the error originated from.

    Annotations
    @inline()
    Example:
    1. server.on("clientError", function (exception, socket) { ... })

  12. def onConnect(callback: Function): server.type

    Permalink
    Annotations
    @inline()
  13. def onRequest(callback: Function): server.type

    Permalink
    Annotations
    @inline()
  14. def onUpgrade(callback: Function): server.type

    Permalink
    Annotations
    @inline()
  15. val server: Server

    Permalink
  16. def toString(): String

    Permalink
    Definition Classes
    Any

Inherited from AnyVal

Inherited from Any

Ungrouped