DateTime
- Type
- Class
- Namespace
- craft\gql\types
- Inherits
- craft\gql\types\DateTime »
GraphQL\Type\Definition\ScalarType
- Implements
- craft\gql\base\SingularTypeInterface
- Since
- 3.3.0
Class DateTime implements the Datetime scalar type for GraphQL.
View source (opens new window)
# Public Properties
Property | Description |
---|---|
description | string (opens new window) |
name | string (opens new window) |
# description
- Type
- string (opens new window)
- Default value
'The
DateTimescalar type represents a point in time.'
View source (opens new window)
# name
- Type
- string (opens new window)
- Default value
'DateTime'
View source (opens new window)
# Public Methods
Method | Description |
---|---|
getName() | |
getType() | Returns a singleton instance to ensure one type per schema. |
parseLiteral() | |
parseValue() | |
serialize() |
# getName()
View source (opens new window)
Returns
# getType()
Returns a singleton instance to ensure one type per schema.
View source (opens new window)
Returns
# parseLiteral()
View source (opens new window)
Arguments
$valueNode
$variables
# parseValue()
View source (opens new window)
Arguments
$value
# serialize()
View source (opens new window)
Arguments
$value