You are here

public static function TimestampScalar::createInstance in GraphQL 8.3

Parameters

\Drupal\graphql\Plugin\SchemaBuilderInterface $builder:

\Drupal\graphql\Plugin\TypePluginManager $manager:

$definition:

$id:

Return value

mixed

Overrides ScalarPluginBase::createInstance

File

src/Plugin/GraphQL/Scalars/Internal/TimestampScalar.php, line 22

Class

TimestampScalar
Plugin annotation @GraphQLScalar( id = "timestamp", name = "Timestamp", type = "timestamp" )

Namespace

Drupal\graphql\Plugin\GraphQL\Scalars\Internal

Code

public static function createInstance(SchemaBuilderInterface $builder, TypePluginManager $manager, $definition, $id) {
  return new IntType([
    'name' => 'Timestamp',
  ]);
}