objectType<P> function
GraphQLObjectType<P>
objectType<P>(
- String name, {
- String? description,
- bool isInterface = false,
- Iterable<
GraphQLObjectField< fields = const [],Object?, Object?, P> > - ResolveType<
GraphQLObjectType< ? resolveType,P> > - IsTypeOf<
P> ? isTypeOf, - Iterable<
GraphQLObjectType> interfaces = const [], - GraphQLTypeDefinitionExtra<
TypeDefinitionNode, TypeExtensionNode> extra = const GraphQLTypeDefinitionExtra.attach([]),
Shorthand for generating a GraphQLObjectType.
Implementation
GraphQLObjectType<P> objectType<P>(
String name, {
String? description,
bool isInterface = false,
Iterable<GraphQLObjectField<Object?, Object?, P>> fields = const [],
ResolveType<GraphQLObjectType<P>>? resolveType,
IsTypeOf<P>? isTypeOf,
Iterable<GraphQLObjectType> interfaces = const [],
GraphQLTypeDefinitionExtra<TypeDefinitionNode, TypeExtensionNode> extra =
const GraphQLTypeDefinitionExtra.attach([]),
}) {
return GraphQLObjectType<P>(
name,
description: description,
isInterface: isInterface,
resolveType: resolveType,
isTypeOf: isTypeOf,
fields: fields,
interfaces: interfaces,
extra: extra,
);
}