client

package
v0.0.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 5, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AroundRequest

type AroundRequest interface {
	AroundRequest(req transport.Request, next RequestHandler) transport.Response
}

type Client

type Client struct {
	Transport transport.Transport
	// contains filtered or unexported fields
}

func (*Client) Mutation

func (c *Client) Mutation(ctx context.Context, operationName string, query string, variables map[string]interface{}, t interface{}) (transport.OperationResponse, error)

Mutation runs a mutation operationName is optional

func (*Client) Query

func (c *Client) Query(ctx context.Context, operationName string, query string, variables map[string]interface{}, t interface{}) (transport.OperationResponse, error)

Query runs a query operationName is optional

func (*Client) RunAroundRequest

func (es *Client) RunAroundRequest(req transport.Request, h RequestHandler) transport.Response

func (*Client) Subscription

func (c *Client) Subscription(ctx context.Context, operationName string, query string, variables map[string]interface{}) transport.Response

Subscription starts a GQL subscription operationName is optional

func (*Client) Use

func (es *Client) Use(e Extension)

type Extension

type Extension interface {
	ExtensionName() string
}

type RequestHandler

type RequestHandler func(req transport.Request) transport.Response

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL