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 AirportResolver ¶
type ComplexityRoot ¶
type ComplexityRoot struct { Airport struct { GetSubsetOfSensors func(childComplexity int, sensorIds []string) int ID func(childComplexity int) int Name func(childComplexity int) int Sensors func(childComplexity int) int } MeasureMeanData struct { Airport func(childComplexity int) int EndDate func(childComplexity int) int ID func(childComplexity int) int Sensor func(childComplexity int) int StartDate func(childComplexity int) int Value func(childComplexity int) int } Measurement struct { ID func(childComplexity int) int Name func(childComplexity int) int Unit func(childComplexity int) int } Query struct { Airports func(childComplexity int) int GetAirportByID func(childComplexity int, id string) int } Sensor struct { Airport func(childComplexity int) int GetMeanMeasureInterval func(childComplexity int, start time.Time, end time.Time, discretize *string, discretizeMode *model.MeanMeasureMode) int GetMeanMeasures func(childComplexity int, day *time.Time) int ID func(childComplexity int) int Measurement func(childComplexity int) int } }
type Config ¶
type Config struct { Resolvers ResolverRoot Directives DirectiveRoot Complexity ComplexityRoot }
type DirectiveRoot ¶
type DirectiveRoot struct { Examples func(ctx context.Context, obj interface{}, next graphql.Resolver, values []*string) (res interface{}, err error) Fake func(ctx context.Context, obj interface{}, next graphql.Resolver, typeArg model.FakeTypes, options *model.FakeOptions, locale *model.FakeLocale) (res interface{}, err error) ListLength func(ctx context.Context, obj interface{}, next graphql.Resolver, min int, max int) (res interface{}, err error) }
type QueryResolver ¶
type ResolverRoot ¶
type ResolverRoot interface { Airport() AirportResolver Query() QueryResolver Sensor() SensorResolver }
type SensorResolver ¶
type SensorResolver interface { GetMeanMeasureInterval(ctx context.Context, obj *model.Sensor, start time.Time, end time.Time, discretize *string, discretizeMode *model.MeanMeasureMode) ([]*model.MeasureMeanData, error) GetMeanMeasures(ctx context.Context, obj *model.Sensor, day *time.Time) ([]*model.MeasureMeanData, error) }
Click to show internal directories.
Click to hide internal directories.