MCPcopy
hub / github.com/graphql/graphql-js / constructor

Method constructor

src/type/definition.ts:4927–4937  ·  view source on GitHub ↗

* Creates a GraphQLInputObjectType instance. * @param config - Configuration describing this object. * @example * ```ts * import { parse } from 'graphql/language'; * import { * GraphQLID, * GraphQLInputObjectType, * GraphQLInt, * GraphQLNonNull, * GraphQLStrin

(config: Readonly<GraphQLInputObjectTypeConfig>)

Source from the content-addressed store, hash-verified

4925 * ```
4926 */
4927 constructor(config: Readonly<GraphQLInputObjectTypeConfig>) {
4928 this.__kind = inputObjectSymbol;
4929 this.name = assertName(config.name);
4930 this.description = config.description;
4931 this.extensions = toObjMapWithSymbols(config.extensions);
4932 this.astNode = config.astNode;
4933 this.extensionASTNodes = config.extensionASTNodes ?? [];
4934 this.isOneOf = config.isOneOf ?? false;
4935
4936 this._fields = defineInputFieldMap.bind(undefined, this, config.fields);
4937 }
4938
4939 /**
4940 * Returns the value used by `Object.prototype.toString`.

Callers

nothing calls this directly

Calls 2

assertNameFunction · 0.90
toObjMapWithSymbolsFunction · 0.90

Tested by

no test coverage detected