platform/graphql_schema/lib/src/argument.dart

15 lines
460 B
Dart
Raw Normal View History

2018-08-02 13:31:54 +00:00
part of graphql_schema.src.schema;
class GraphQLFieldArgument<Value, Serialized> {
final String name;
final GraphQLType<Value, Serialized> type;
final Value defaultValue;
2018-08-03 17:45:40 +00:00
final String description;
2018-08-02 13:50:31 +00:00
/// If [defaultValue] is `null`, and `null` is a valid value for this argument, set this to `true`.
final bool defaultsToNull;
GraphQLFieldArgument(this.name, this.type,
2018-08-03 17:45:40 +00:00
{this.defaultValue, this.defaultsToNull: false, this.description});
2018-08-02 13:31:54 +00:00
}