FieldDefinition
in package
Tags
Table of Contents
- $args : array<string|int, mixed>
- $argsMapper : callable|null
- Callback to transform args to value object.
- $astNode : FieldDefinitionNode|null
- $complexityFn : callable|null
- $config : array<string|int, mixed>
- Original field definition config.
- $deprecationReason : string|null
- $description : string|null
- $name : string
- $resolveFn : callable|null
- Callback for resolving field value given parent value.
- $visible : callable|bool
- $type : Type
- __construct() : mixed
- assertValid() : void
- defineFieldMap() : array<string, self|\Automattic\WooCommerce\Vendor\GraphQL\Type\Definition\UnresolvedFieldDefinition>
- getArg() : Argument|null
- getName() : string
- getType() : Type|OutputType
- isDeprecated() : bool
- isVisible() : bool
Properties
$args
public
array<string|int, mixed>
$args
$argsMapper
Callback to transform args to value object.
public
callable|null
$argsMapper
Tags
$astNode
public
FieldDefinitionNode|null
$astNode
$complexityFn
public
callable|null
$complexityFn
Tags
$config
Original field definition config.
public
array<string|int, mixed>
$config
Tags
$deprecationReason
public
string|null
$deprecationReason
$description
public
string|null
$description
$name
public
string
$name
$resolveFn
Callback for resolving field value given parent value.
public
callable|null
$resolveFn
Tags
$visible
public
callable|bool
$visible
Tags
$type
private
Type
$type
Methods
__construct()
public
__construct(FieldDefinitionConfig $config) : mixed
Parameters
- $config : FieldDefinitionConfig
Return values
mixed —assertValid()
public
assertValid(Type|NamedType $parentType) : void
Parameters
Tags
Return values
void —defineFieldMap()
public
static defineFieldMap(ObjectType|InterfaceType $parentType, callable|iteratable<string|int, mixed> $fields) : array<string, self|\Automattic\WooCommerce\Vendor\GraphQL\Type\Definition\UnresolvedFieldDefinition>
Parameters
- $parentType : ObjectType|InterfaceType
- $fields : callable|iteratable<string|int, mixed>
Tags
Return values
array<string, self|\Automattic\WooCommerce\Vendor\GraphQL\Type\Definition\UnresolvedFieldDefinition> —getArg()
public
getArg(string $name) : Argument|null
Parameters
- $name : string
Return values
Argument|null —getName()
public
getName() : string
Return values
string —getType()
public
getType() : Type|OutputType
Return values
Type|OutputType —isDeprecated()
public
isDeprecated() : bool
Return values
bool —isVisible()
public
isVisible() : bool
