Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewExecutableSchema ¶
func NewExecutableSchema(cfg Config) graphql.ExecutableSchema
NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.
Types ¶
type AftermarketDeviceResolver ¶
type AftermarketDeviceResolver interface { Manufacturer(ctx context.Context, obj *model.AftermarketDevice) (*model.Manufacturer, error) Vehicle(ctx context.Context, obj *model.AftermarketDevice) (*model.Vehicle, error) }
type ComplexityRoot ¶
type ComplexityRoot struct { AftermarketDevice struct { Address func(childComplexity int) int Beneficiary func(childComplexity int) int ClaimedAt func(childComplexity int) int ID func(childComplexity int) int Imei func(childComplexity int) int Manufacturer func(childComplexity int) int MintedAt func(childComplexity int) int Name func(childComplexity int) int Owner func(childComplexity int) int Serial func(childComplexity int) int TokenID func(childComplexity int) int Vehicle func(childComplexity int) int } AftermarketDeviceConnection struct { Edges func(childComplexity int) int Nodes func(childComplexity int) int PageInfo func(childComplexity int) int TotalCount func(childComplexity int) int } AftermarketDeviceEdge struct { Cursor func(childComplexity int) int Node func(childComplexity int) int } DCN struct { ExpiresAt func(childComplexity int) int MintedAt func(childComplexity int) int Name func(childComplexity int) int Node func(childComplexity int) int Owner func(childComplexity int) int Vehicle func(childComplexity int) int } Definition struct { Make func(childComplexity int) int Model func(childComplexity int) int URI func(childComplexity int) int Year func(childComplexity int) int } Manufacturer struct { ID func(childComplexity int) int MintedAt func(childComplexity int) int Name func(childComplexity int) int Owner func(childComplexity int) int TokenID func(childComplexity int) int } PageInfo struct { EndCursor func(childComplexity int) int HasNextPage func(childComplexity int) int HasPreviousPage func(childComplexity int) int StartCursor func(childComplexity int) int } Privilege struct { ExpiresAt func(childComplexity int) int ID func(childComplexity int) int SetAt func(childComplexity int) int User func(childComplexity int) int } PrivilegeEdge struct { Cursor func(childComplexity int) int Node func(childComplexity int) int } PrivilegesConnection struct { Edges func(childComplexity int) int Nodes func(childComplexity int) int PageInfo func(childComplexity int) int TotalCount func(childComplexity int) int } Query struct { AftermarketDevice func(childComplexity int, by model.AftermarketDeviceBy) int AftermarketDevices func(childComplexity int, first *int, after *string, last *int, before *string, filterBy *model.AftermarketDevicesFilter) int Dcn func(childComplexity int, by model.DCNBy) int Node func(childComplexity int, id string) int Vehicle func(childComplexity int, tokenID int) int Vehicles func(childComplexity int, first *int, after *string, last *int, before *string, filterBy *model.VehiclesFilter) int } SyntheticDevice struct { Address func(childComplexity int) int IntegrationID func(childComplexity int) int MintedAt func(childComplexity int) int TokenID func(childComplexity int) int } Vehicle struct { AftermarketDevice func(childComplexity int) int Dcn func(childComplexity int) int Definition func(childComplexity int) int ID func(childComplexity int) int Manufacturer func(childComplexity int) int MintedAt func(childComplexity int) int Name func(childComplexity int) int Owner func(childComplexity int) int Privileges func(childComplexity int, first *int, after *string, last *int, before *string, filterBy model.PrivilegeFilterBy) int SyntheticDevice func(childComplexity int) int TokenID func(childComplexity int) int } VehicleConnection struct { Edges func(childComplexity int) int Nodes func(childComplexity int) int PageInfo func(childComplexity int) int TotalCount func(childComplexity int) int } VehicleEdge struct { Cursor func(childComplexity int) int Node func(childComplexity int) int } }
type Config ¶
type Config struct { Schema *ast.Schema Resolvers ResolverRoot Directives DirectiveRoot Complexity ComplexityRoot }
type DCNResolver ¶
type DirectiveRoot ¶
type QueryResolver ¶
type QueryResolver interface { Node(ctx context.Context, id string) (model.Node, error) Vehicle(ctx context.Context, tokenID int) (*model.Vehicle, error) Vehicles(ctx context.Context, first *int, after *string, last *int, before *string, filterBy *model.VehiclesFilter) (*model.VehicleConnection, error) AftermarketDevice(ctx context.Context, by model.AftermarketDeviceBy) (*model.AftermarketDevice, error) AftermarketDevices(ctx context.Context, first *int, after *string, last *int, before *string, filterBy *model.AftermarketDevicesFilter) (*model.AftermarketDeviceConnection, error) Dcn(ctx context.Context, by model.DCNBy) (*model.Dcn, error) }
type Resolver ¶
type Resolver struct {
Repo *repositories.Repository
}
func NewResolver ¶
func NewResolver(repo *repositories.Repository) *Resolver
func (*Resolver) AftermarketDevice ¶
func (r *Resolver) AftermarketDevice() AftermarketDeviceResolver
AftermarketDevice returns AftermarketDeviceResolver implementation.
func (*Resolver) Query ¶
func (r *Resolver) Query() QueryResolver
Query returns QueryResolver implementation.
func (*Resolver) Vehicle ¶
func (r *Resolver) Vehicle() VehicleResolver
Vehicle returns VehicleResolver implementation.
type ResolverRoot ¶
type ResolverRoot interface { AftermarketDevice() AftermarketDeviceResolver DCN() DCNResolver Query() QueryResolver Vehicle() VehicleResolver }
type VehicleResolver ¶
type VehicleResolver interface { Manufacturer(ctx context.Context, obj *model.Vehicle) (*model.Manufacturer, error) AftermarketDevice(ctx context.Context, obj *model.Vehicle) (*model.AftermarketDevice, error) Privileges(ctx context.Context, obj *model.Vehicle, first *int, after *string, last *int, before *string, filterBy model.PrivilegeFilterBy) (*model.PrivilegesConnection, error) SyntheticDevice(ctx context.Context, obj *model.Vehicle) (*model.SyntheticDevice, error) Dcn(ctx context.Context, obj *model.Vehicle) (*model.Dcn, error) }
Click to show internal directories.
Click to hide internal directories.