package gapi-ocaml

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module GapiConversationSource

Server conversation manager.

Sourcemodule Session : sig ... end

Defines the session that stores the current state of a conversation.

Sourceval request : ?header_list:GapiCore.Header.t list -> ?post_data:GapiCore.PostData.t -> ?media_download:GapiMediaResource.download -> GapiCore.HttpMethod.t -> Session.t -> string -> (GapiPipe.OcamlnetPipe.t -> int -> GapiCore.Header.t list -> Session.t -> 'a) -> 'a * Session.t
Sourceval with_session : ?auth_context:Session.auth_context -> GapiConfig.t -> [ `Initialized ] GapiCurl.t -> (Session.t -> 'a) -> 'a

Initializes a new session and executes a batch of requests to the server.

with_session config curl interact initializes a new session using config as configuration and curl as the initialized Ocurl wrapper, and executes interact in the context of the created session. Then it disposes the session, and returns the result of interact.

  • parameter auth_context

    Optional current authorization context. Defaults to NoAuth.

Sourceval with_curl : ?auth_context:Session.auth_context -> GapiConfig.t -> (Session.t -> 'a) -> 'a

Initializes a new connection to the server and executes a batch of requests.

with_curl config interact initializes a new connection using config as configuration, and executes interact in the context of the created connection. Then it disposes the connection, and returns the result of interact.

  • parameter auth_context

    Optional current authorization context. Defaults to NoAuth.

Sourceval read_all : ?auto_close:bool -> GapiPipe.OcamlnetPipe.t -> string

Reads a pipe until EOF.

  • parameter auto_close

    Closes the pipe after reading. Defaults to true.

Sourceval parse_error : GapiPipe.OcamlnetPipe.t -> int -> Session.t -> 'a
Sourceexception ConversationException of string
Sourcetype ('a, 'b) iter =
  1. | Done of 'b
  2. | Continue of 'a -> ('a, 'b) iter
  3. | Error of string
Sourceval loop : ('a -> ('a, 'b) iter) -> 'a -> 'b
OCaml

Innovation. Community. Security.