Reference
C
Class

ApiPlatform\GraphQl\Type\Definition\IterableType

Represents an iterable type.

class ApiPlatform\GraphQl\Type\Definition\IterableType extends GraphQL\Type\Definition\ScalarType implements JsonSerializable, Stringable, GraphQL\Type\Definition\OutputType, GraphQL\Type\Definition\InputType, GraphQL\Type\Definition\LeafType, GraphQL\Type\Definition\NullableType, GraphQL\Type\Definition\NamedType, `<a href="/docs/reference/GraphQl/Type/Definition/TypeInterface">ApiPlatform\GraphQl\Type\Definition\TypeInterface</a>`
{
    public __construct()
    public getName(): string
    public serialize($value): iterable
    public parseValue($value): iterable
    public parseLiteral(GraphQL\Language\AST\ObjectValueNode|GraphQL\Language\AST\ListValueNode|GraphQL\Language\AST\IntValueNode|GraphQL\Language\AST\FloatValueNode|GraphQL\Language\AST\StringValueNode|GraphQL\Language\AST\BooleanValueNode|GraphQL\Language\AST\NullValueNode $valueNode, null|array $variables): array|string|int|float|bool
    public assertValid(): null
    public astNode(): GraphQL\Language\AST\ScalarTypeDefinitionNode
    public extensionASTNodes(): array&lt;int, GraphQL\Language\AST\ScalarTypeExtensionNode&gt;
    public int(): GraphQL\Type\Definition\ScalarType
    public float(): GraphQL\Type\Definition\ScalarType
    public string(): GraphQL\Type\Definition\ScalarType
    public boolean(): GraphQL\Type\Definition\ScalarType
    public id(): GraphQL\Type\Definition\ScalarType
    public listOf(GraphQL\Type\Definition\T|callable $type): GraphQL\Type\Definition\ListOfType[]
    public nonNull(callable $type): GraphQL\Type\Definition\NonNull
    public builtInTypes(): array&lt;string&gt;
    public getStandardTypes(): array&lt;string, GraphQL\Type\Definition\ScalarType&gt;
    public overrideStandardTypes(array $types): null
    public isInputType($type): bool
    public getNamedType(null|GraphQL\Type\Definition\Type $type): null
    public isOutputType($type): bool
    public isLeafType($type): bool
    public isCompositeType($type): bool
    public isAbstractType($type): bool
    public getNullableType(GraphQL\Type\Definition\Type $type)
    public toString(): string
    public __toString(): string
    public jsonSerialize(): string
    protected inferName(): string
    public isBuiltInType(): bool
    public name(): string
    public description(): string
}
class ApiPlatform\GraphQl\Type\Definition\IterableType extends GraphQL\Type\Definition\ScalarType implements JsonSerializable, Stringable, GraphQL\Type\Definition\OutputType, GraphQL\Type\Definition\InputType, GraphQL\Type\Definition\LeafType, GraphQL\Type\Definition\NullableType, GraphQL\Type\Definition\NamedType, `<a href="/docs/reference/GraphQl/Type/Definition/TypeInterface">ApiPlatform\GraphQl\Type\Definition\TypeInterface</a>`
{
    public __construct()
    public getName(): string
    public serialize($value): iterable
    public parseValue($value): iterable
    public parseLiteral(GraphQL\Language\AST\ObjectValueNode|GraphQL\Language\AST\ListValueNode|GraphQL\Language\AST\IntValueNode|GraphQL\Language\AST\FloatValueNode|GraphQL\Language\AST\StringValueNode|GraphQL\Language\AST\BooleanValueNode|GraphQL\Language\AST\NullValueNode $valueNode, null|array $variables): array|string|int|float|bool
    public assertValid(): null
    public astNode(): GraphQL\Language\AST\ScalarTypeDefinitionNode
    public extensionASTNodes(): array&lt;int, GraphQL\Language\AST\ScalarTypeExtensionNode&gt;
    public int(): GraphQL\Type\Definition\ScalarType
    public float(): GraphQL\Type\Definition\ScalarType
    public string(): GraphQL\Type\Definition\ScalarType
    public boolean(): GraphQL\Type\Definition\ScalarType
    public id(): GraphQL\Type\Definition\ScalarType
    public listOf(GraphQL\Type\Definition\T|callable $type): GraphQL\Type\Definition\ListOfType[]
    public nonNull(callable $type): GraphQL\Type\Definition\NonNull
    public builtInTypes(): array&lt;string&gt;
    public getStandardTypes(): array&lt;string, GraphQL\Type\Definition\ScalarType&gt;
    public overrideStandardTypes(array $types): null
    public isInputType($type): bool
    public getNamedType(null|GraphQL\Type\Definition\Type $type): null
    public isOutputType($type): bool
    public isLeafType($type): bool
    public isCompositeType($type): bool
    public isAbstractType($type): bool
    public getNullableType(GraphQL\Type\Definition\Type $type)
    public toString(): string
    public __toString(): string
    public jsonSerialize(): string
    protected inferName(): string
    public isBuiltInType(): bool
    public name(): string
    public description(): string
}

Properties

astNode

GraphQL\Language\AST\ScalarTypeDefinitionNode $astNode
GraphQL\Language\AST\ScalarTypeDefinitionNode $astNode

extensionASTNodes

array $extensionASTNodes
array $extensionASTNodes

config

array $config
array $config

standardTypes

array&lt;string, GraphQL\Type\Definition\ScalarType&gt; $standardTypes
array&lt;string, GraphQL\Type\Definition\ScalarType&gt; $standardTypes

name

string $name
string $name

description

string $description
string $description

Methods

__construct

public __construct()
public __construct()

getName

public getName(): string
public getName(): string

Returns

string

serialize

Serializes an internal value to include in a response.Should throw an exception on invalid values.Serializes an internal value to include in a response.Should throw an exception on invalid values.

public serialize($value): iterable
public serialize($value): iterable

Parameters

value

Returns

iterable

parseValue

Parses an externally provided value (query variable) to use as an input.Should throw an exception with a client friendly message on invalid values, @see ClientAware.Parses an externally provided value (query variable) to use as an input.Should throw an exception with a client friendly message on invalid values, @see ClientAware.

public parseValue($value): iterable
public parseValue($value): iterable

Parameters

value

Returns

iterable

parseLiteral

Parses an externally provided literal value (hardcoded in GraphQL query) to use as an input.Should throw an exception with a client friendly message on invalid value nodes, @see ClientAware.Parses an externally provided literal value (hardcoded in GraphQL query) to use as an input.Should throw an exception with a client friendly message on invalid value nodes, @see ClientAware.

public parseLiteral(GraphQL\Language\AST\ObjectValueNode|GraphQL\Language\AST\ListValueNode|GraphQL\Language\AST\IntValueNode|GraphQL\Language\AST\FloatValueNode|GraphQL\Language\AST\StringValueNode|GraphQL\Language\AST\BooleanValueNode|GraphQL\Language\AST\NullValueNode $valueNode, null|array $variables): array|string|int|float|bool
public parseLiteral(GraphQL\Language\AST\ObjectValueNode|GraphQL\Language\AST\ListValueNode|GraphQL\Language\AST\IntValueNode|GraphQL\Language\AST\FloatValueNode|GraphQL\Language\AST\StringValueNode|GraphQL\Language\AST\BooleanValueNode|GraphQL\Language\AST\NullValueNode $valueNode, null|array $variables): array|string|int|float|bool

Parameters

valueNodeGraphQL\Language\AST\ObjectValueNode
GraphQL\Language\AST\ListValueNode
GraphQL\Language\AST\IntValueNode
GraphQL\Language\AST\FloatValueNode
GraphQL\Language\AST\StringValueNode
GraphQL\Language\AST\BooleanValueNode
GraphQL\Language\AST\NullValueNode
variablesarray

Returns

array
string
int
float
bool

Copyright © 2023 Kévin Dunglas

Sponsored by Les-Tilleuls.coop