graphql

package
v0.2.5 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const ConnectTimeout = 10 * time.Second

Variables

This section is empty.

Functions

This section is empty.

Types

type GraphqlClient

type GraphqlClient struct {
	Host   string
	Client *graphql.Client
}

func NewGraphqlQueryClient

func NewGraphqlQueryClient(host string, token string) GraphqlClient

func (GraphqlClient) Connect

func (c GraphqlClient) Connect() error

type GraphqlSubscriptionClient

type GraphqlSubscriptionClient struct {
	Client *graphql.SubscriptionClient
	Id     string
	// contains filtered or unexported fields
}

func NewGraphqlSubscriptionClient

func NewGraphqlSubscriptionClient(host string, token string) (error, GraphqlSubscriptionClient)

func (GraphqlSubscriptionClient) GetState

func (c GraphqlSubscriptionClient) GetState() bool

func (GraphqlSubscriptionClient) Start

func (c GraphqlSubscriptionClient) Start() error

func (GraphqlSubscriptionClient) Stop

func (GraphqlSubscriptionClient) Subscribe

func (c GraphqlSubscriptionClient) Subscribe(query interface{}, handler func(message *json.RawMessage, err error) error) error

func (GraphqlSubscriptionClient) Unsubscribe

func (c GraphqlSubscriptionClient) Unsubscribe() error

Jump to

Keyboard shortcuts

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