common

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AuthorizationHeader  = "Authorization"
	XTenantContextHeader = "X-Tenant-Context"
)

Variables

This section is empty.

Functions

func IntP

func IntP(i int) *int

IntP is a helper function to return a pointer to an int which is useful for optional int parameters in APIs.

func StringP

func StringP(s string) *string

StringP is a helper function to return a pointer to a string which is useful for optional string parameters in APIs.

Types

type ID

type ID string

type IDs

type IDs []ID

type Object

type Object map[string]interface{}

Object is a generic json container

func (Object) Keys

func (o Object) Keys() []string

func (Object) MarshalGQL

func (o Object) MarshalGQL(w io.Writer)

func (*Object) UnmarshalGQL

func (o *Object) UnmarshalGQL(v interface{}) error

type ObjectMetaInput

type ObjectMetaInput struct {
	Name        string  `json:"name"`
	Description *string `json:"description"`
	Tags        Tags    `json:"tags,omitempty"`
}

type Pagination

type Pagination struct {
	Page    *int `json:"page"`
	PerPage *int `json:"perPage"`
}

func NewPaginationOptions

func NewPaginationOptions(page, perPage int) Pagination

type Tags

type Tags []string

Jump to

Keyboard shortcuts

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