ObjectType ​
- Type
- Abstract Class
- Namespace
- craft\gql\base
- Inherits
- craft\gql\base\ObjectType »
GraphQL\Type\Definition\ObjectType
- Extended by
- craft\gql\types\TableRow, craft\gql\types\elements\Address, craft\gql\types\elements\Asset, craft\gql\types\elements\Category, craft\gql\types\elements\Element, craft\gql\types\elements\Entry, craft\gql\types\elements\GlobalSet, craft\gql\types\elements\Tag, craft\gql\types\elements\User
- Since
- 3.3.0
Class ObjectType
Public Methods ​
Method | Description |
---|---|
__construct() | |
resolveWithDirectives() | Resolve a value with the directives that apply to it. |
__construct()
​
Arguments ​
$config
resolveWithDirectives()
​
Resolve a value with the directives that apply to it.
Arguments ​
$source
(mixed
) – The parent data source to use for resolving this field$arguments
(array) – Arguments for resolving this field.$context
(mixed
) – The context shared between all resolvers$resolveInfo
(\GraphQL\Type\Definition\ResolveInfo
) – The resolve information
Returns ​
mixed
– $result
Throws ​
- craft\errors\GqlException
if an error occurs
Protected Methods ​
Method | Description |
---|---|
resolve() | Resolve a field value with arguments, context and resolve information. |
resolve()
​
Resolve a field value with arguments, context and resolve information.
Arguments ​
$source
(mixed
) – The parent data source to use for resolving this field$arguments
(array) – Arguments for resolving this field.$context
(mixed
) – The context shared between all resolvers$resolveInfo
(\GraphQL\Type\Definition\ResolveInfo
) – The resolve information
Returns ​
mixed
– $result