@types/spdy

  • Version 3.4.4
  • Published
  • 1 dependency
  • MIT license

Install

npm i @types/spdy
yarn add @types/spdy
pnpm add @types/spdy

Overview

TypeScript definitions for node-spdy

Index

Functions

function createAgent

createAgent: {
(base: any, options: AgentOptions): Agent | PlainAgent;
(options: agent.AgentOptions): agent.Agent | agent.PlainAgent;
};

    function createServer

    createServer: {
    (
    base: any,
    options: ServerOptions,
    handler: (request: any, response: any) => void
    ): any;
    (
    options: server.ServerOptions,
    handler: (request: any, response: any) => void
    ): any;
    (handler: (request: any, response: any) => void): any;
    };

      Interfaces

      interface Handle

      interface Handle {}

        method assignClientRequest

        assignClientRequest: (req: any) => void;

          method assignRequest

          assignRequest: (req: any) => void;

            method assignResponse

            assignResponse: (res: any) => void;

              method assignSocket

              assignSocket: (socket: Socket, options: object) => void;

                method create

                create: (options: object, stream: any, socket: Socket) => Handle;

                  method emitRequest

                  emitRequest: () => void;

                    method emitResponse

                    emitResponse: (status: any, headers: any) => void;

                      method getStream

                      getStream: (callback?: (stream: any) => void) => any;

                        Type Aliases

                        type Agent

                        type Agent = agent.Agent;

                          type AgentOptions

                          type AgentOptions = agent.AgentOptions;

                            type IncomingMessage

                            type IncomingMessage = server.IncomingMessage;

                              type PlainAgent

                              type PlainAgent = agent.PlainAgent;

                                type PlainServer

                                type PlainServer = server.PlainServer;

                                  type Server

                                  type Server = server.Server;

                                    type ServerOptions

                                    type ServerOptions = server.ServerOptions;

                                      type ServerRequest

                                      type ServerRequest = server.IncomingMessage;

                                        type ServerResponse

                                        type ServerResponse = server.ServerResponse;

                                          type Socket

                                          type Socket = socket.Socket;

                                            Namespaces

                                            namespace agent

                                            namespace agent {}

                                              function create

                                              create: (base: any, options: AgentOptions) => Agent | PlainAgent;

                                                class Agent

                                                class Agent extends https.Agent {}

                                                  class PlainAgent

                                                  class PlainAgent extends http.Agent {}

                                                    interface AgentOptions

                                                    interface AgentOptions extends https.AgentOptions {}

                                                      property port

                                                      port?: number;

                                                        property spdy

                                                        spdy?: {
                                                        plain?: boolean;
                                                        ssl?: boolean;
                                                        'x-forwarded-for'?: string;
                                                        protocol?: string;
                                                        protocols?: string[];
                                                        };

                                                          namespace request

                                                          namespace request {}

                                                            function onNewListener

                                                            onNewListener: (type: string) => void;

                                                              namespace response

                                                              namespace response {}

                                                                function end

                                                                end: (data: any, encoding: string, callback: () => void) => void;

                                                                  function writeHead

                                                                  writeHead: {
                                                                  (statusCode: number, reason: string, obj: object): void;
                                                                  (statusCode: number, obj: object): void;
                                                                  };

                                                                    namespace server

                                                                    namespace server {}

                                                                      function create

                                                                      create: {
                                                                      (
                                                                      base: any,
                                                                      options: any,
                                                                      handler: (
                                                                      request: any,
                                                                      response: ServerResponse | http.ServerResponse
                                                                      ) => void
                                                                      ): any;
                                                                      (options: any, handler: (request: any, response: any) => void): any;
                                                                      (handler: (request: any, response: any) => void): any;
                                                                      };

                                                                        interface PushOptions

                                                                        interface PushOptions {}

                                                                          property method

                                                                          method?: string;

                                                                            property request

                                                                            request?: any;

                                                                              property response

                                                                              response?: any;

                                                                                property status

                                                                                status?: number;

                                                                                  interface ServerOptions

                                                                                  interface ServerOptions extends https.ServerOptions {}

                                                                                    property spdy

                                                                                    spdy?: {
                                                                                    protocols?: Protocol[];
                                                                                    plain?: boolean;
                                                                                    'x-forwarded-for'?: boolean;
                                                                                    connection?: {
                                                                                    windowSize?: number;
                                                                                    autoSpdy31?: boolean;
                                                                                    };
                                                                                    };

                                                                                      interface ServerResponse

                                                                                      interface ServerResponse extends http.ServerResponse {}

                                                                                        method push

                                                                                        push: (filename: string, options: PushOptions) => any;

                                                                                          type IncomingMessage

                                                                                          type IncomingMessage = http.IncomingMessage;

                                                                                            type PlainServer

                                                                                            type PlainServer = http.Server;

                                                                                              type Protocol

                                                                                              type Protocol = 'h2' | 'spdy/3.1' | 'spdy/3' | 'spdy/2' | 'http/1.1' | 'http/1.0';

                                                                                                type Server

                                                                                                type Server = https.Server;

                                                                                                  namespace socket

                                                                                                  namespace socket {}

                                                                                                    interface Socket

                                                                                                    interface Socket {}

                                                                                                      Package Files (1)

                                                                                                      Dependencies (1)

                                                                                                      Dev Dependencies (0)

                                                                                                      No dev dependencies.

                                                                                                      Peer Dependencies (0)

                                                                                                      No peer dependencies.

                                                                                                      Badge

                                                                                                      To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                                                                                      You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/spdy.

                                                                                                      • Markdown
                                                                                                        [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@types/spdy)
                                                                                                      • HTML
                                                                                                        <a href="https://www.jsdocs.io/package/@types/spdy"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>