Documentation
¶
Index ¶
- Constants
- Variables
- func Install[T dagql.Typed](srv *dagql.Server)
- type Directive
- type DirectiveLocation
- type EnumValue
- type Field
- type InputValue
- type Response
- type ResponseDirective
- type ResponseDirectiveLocation
- type ResponseEnumValue
- type ResponseField
- type ResponseInputValue
- type ResponseInputValues
- type ResponseNamedType
- type ResponseSchema
- type ResponseSchemaTypes
- type ResponseType
- type ResponseTypeKind
- type ResponseTypeRef
- type Scalar
- type Schema
- func (s *Schema) Description() string
- func (s *Schema) Directives() []*Directive
- func (s *Schema) MutationType() *Type
- func (s *Schema) QueryType() *Type
- func (s *Schema) SubscriptionType() *Type
- func (s *Schema) Type() *ast.Type
- func (s *Schema) TypeDescription() string
- func (s *Schema) Types() []*Type
- type Type
- func (t *Type) Description() string
- func (t *Type) EnumValues(includeDeprecated bool) []*EnumValue
- func (t *Type) Fields(includeDeprecated bool) []*Field
- func (t *Type) InputFields() []*InputValue
- func (t *Type) Interfaces() []*Type
- func (t *Type) Kind() string
- func (t *Type) Name() *string
- func (t *Type) OfType() *Type
- func (t *Type) PossibleTypes() []*Type
- func (t *Type) SpecifiedByURL() *string
- func (s *Type) Type() *ast.Type
- func (s *Type) TypeDescription() string
- type TypeKind
Constants ¶
View Source
const ( ResponseTypeKindScalar = ResponseTypeKind("SCALAR") ResponseTypeKindObject = ResponseTypeKind("OBJECT") ResponseTypeKindInterface = ResponseTypeKind("INTERFACE") ResponseTypeKindUnion = ResponseTypeKind("UNION") ResponseTypeKindEnum = ResponseTypeKind("ENUM") ResponseTypeKindInputObject = ResponseTypeKind("INPUT_OBJECT") ResponseTypeKindList = ResponseTypeKind("LIST") ResponseTypeKindNonNull = ResponseTypeKind("NON_NULL") )
View Source
const ( ScalarInt = Scalar("Int") ScalarFloat = Scalar("Float") ScalarString = Scalar("String") ScalarBoolean = Scalar("Boolean") )
Variables ¶
View Source
var DirectiveLocations = dagql.NewEnum[DirectiveLocation](
"QUERY",
"MUTATION",
"SUBSCRIPTION",
"FIELD",
"FRAGMENT_DEFINITION",
"FRAGMENT_SPREAD",
"INLINE_FRAGMENT",
"VARIABLE_DEFINITION",
"SCHEMA",
"SCALAR",
"OBJECT",
"FIELD_DEFINITION",
"ARGUMENT_DEFINITION",
"INTERFACE",
"UNION",
"ENUM",
"ENUM_VALUE",
"INPUT_OBJECT",
"INPUT_FIELD_DEFINITION",
)
View Source
var Query string
View Source
var TypeKinds = dagql.NewEnum[TypeKind](
"SCALAR",
"OBJECT",
"INTERFACE",
"UNION",
"ENUM",
"INPUT_OBJECT",
"LIST",
"NON_NULL",
)
Functions ¶
Types ¶
type Directive ¶
type Directive struct { Name string Locations []string Args []*InputValue IsRepeatable bool // contains filtered or unexported fields }
func (*Directive) Description ¶
func (*Directive) TypeDescription ¶
type DirectiveLocation ¶
type DirectiveLocation string
func (DirectiveLocation) Decoder ¶
func (k DirectiveLocation) Decoder() dagql.InputDecoder
func (DirectiveLocation) ToLiteral ¶
func (k DirectiveLocation) ToLiteral() *idproto.Literal
func (DirectiveLocation) Type ¶
func (k DirectiveLocation) Type() *ast.Type
func (DirectiveLocation) TypeDescription ¶
func (s DirectiveLocation) TypeDescription() string
type EnumValue ¶
type EnumValue struct { Name string // contains filtered or unexported fields }
func (*EnumValue) DeprecationReason ¶
func (*EnumValue) Description ¶
func (*EnumValue) IsDeprecated ¶
func (*EnumValue) TypeDescription ¶
type Field ¶
type Field struct { Name string Type_ *Type Args []*InputValue // contains filtered or unexported fields }
func (*Field) DeprecationReason ¶
func (*Field) Description ¶
func (*Field) IsDeprecated ¶
func (*Field) TypeDescription ¶
type InputValue ¶
type InputValue struct { Name string DefaultValue *string Type_ *Type // contains filtered or unexported fields }
func (*InputValue) DeprecationReason ¶
func (f *InputValue) DeprecationReason() *string
func (*InputValue) Description ¶
func (f *InputValue) Description() string
func (*InputValue) IsDeprecated ¶
func (f *InputValue) IsDeprecated() bool
func (*InputValue) Type ¶
func (s *InputValue) Type() *ast.Type
func (*InputValue) TypeDescription ¶
func (s *InputValue) TypeDescription() string
type Response ¶
type Response struct {
Schema *ResponseSchema `json:"__schema"`
}
Response is the introspection query response
type ResponseDirective ¶
type ResponseDirective struct { Name string `json:"name"` Description string `json:"description"` Locations []ResponseDirectiveLocation `json:"locations"` Args []ResponseInputValue `json:"args"` IsRepeatable bool `json:"isRepeatable"` }
type ResponseDirectiveLocation ¶
type ResponseDirectiveLocation string
type ResponseEnumValue ¶
type ResponseField ¶
type ResponseField struct { Name string `json:"name"` Description string `json:"description"` TypeRef *ResponseTypeRef `json:"type"` Args ResponseInputValues `json:"args"` IsDeprecated bool `json:"isDeprecated"` DeprecationReason string `json:"deprecationReason"` ParentObject *Type `json:"-"` }
type ResponseInputValue ¶
type ResponseInputValues ¶
type ResponseInputValues []ResponseInputValue
func (ResponseInputValues) HasOptionals ¶
func (i ResponseInputValues) HasOptionals() bool
type ResponseNamedType ¶
type ResponseNamedType struct {
Name string `json:"name"`
}
type ResponseSchema ¶
type ResponseSchema struct { QueryType ResponseNamedType `json:"queryType"` MutationType *ResponseNamedType `json:"mutationType,omitempty"` SubscriptionType *ResponseNamedType `json:"subscriptionType,omitempty"` Types ResponseSchemaTypes `json:"types"` // Interfaces ResponseSchemaTypes `json:"interfaces"` // PossibleTypes ResponseSchemaTypes `json:"possibleTypes"` Directives []ResponseDirective `json:"directives"` }
func (*ResponseSchema) Mutation ¶
func (s *ResponseSchema) Mutation() *ResponseType
func (*ResponseSchema) Query ¶
func (s *ResponseSchema) Query() *ResponseType
func (*ResponseSchema) Subscription ¶
func (s *ResponseSchema) Subscription() *ResponseType
type ResponseSchemaTypes ¶
type ResponseSchemaTypes []*ResponseType
func (ResponseSchemaTypes) Get ¶
func (t ResponseSchemaTypes) Get(name string) *ResponseType
type ResponseType ¶
type ResponseType struct { Kind ResponseTypeKind `json:"kind"` Name string `json:"name"` Description string `json:"description,omitempty"` Fields []*ResponseField `json:"fields,omitempty"` InputFields []ResponseInputValue `json:"inputFields,omitempty"` EnumValues []ResponseEnumValue `json:"enumValues,omitempty"` Interfaces ResponseSchemaTypes `json:"interfaces,omitempty"` PossibleTypes ResponseSchemaTypes `json:"possibleTypes,omitempty"` }
type ResponseTypeKind ¶
type ResponseTypeKind string
type ResponseTypeRef ¶
type ResponseTypeRef struct { Kind ResponseTypeKind `json:"kind"` Name string `json:"name,omitempty"` OfType *ResponseTypeRef `json:"ofType,omitempty"` }
func (ResponseTypeRef) IsList ¶
func (r ResponseTypeRef) IsList() bool
func (ResponseTypeRef) IsObject ¶
func (r ResponseTypeRef) IsObject() bool
func (ResponseTypeRef) IsOptional ¶
func (r ResponseTypeRef) IsOptional() bool
func (ResponseTypeRef) IsScalar ¶
func (r ResponseTypeRef) IsScalar() bool
type Schema ¶
type Schema struct {
// contains filtered or unexported fields
}
func WrapSchema ¶
func (*Schema) Description ¶
func (*Schema) Directives ¶
func (*Schema) MutationType ¶
func (*Schema) SubscriptionType ¶
func (*Schema) TypeDescription ¶
type Type ¶
type Type struct {
// contains filtered or unexported fields
}
func WrapTypeFromDef ¶
func WrapTypeFromDef(s *ast.Schema, def *ast.Definition) *Type
func (*Type) Description ¶
func (*Type) EnumValues ¶
func (*Type) InputFields ¶
func (t *Type) InputFields() []*InputValue
func (*Type) Interfaces ¶
func (*Type) PossibleTypes ¶
func (*Type) SpecifiedByURL ¶
func (*Type) TypeDescription ¶
type TypeKind ¶
type TypeKind string
func (TypeKind) Decoder ¶
func (k TypeKind) Decoder() dagql.InputDecoder
func (TypeKind) TypeDescription ¶
Click to show internal directories.
Click to hide internal directories.