Class InputValuesAsFieldsMixin
Constructors
constructor
-
Parameters
Properties
Readonly _fields
_fields
: Crud<InputValueDefinitionNode, InputValueDefinitionApi, { defaultValue
?: GQL.ValueNode; description
?: StringValueNodeProps | StringValueNode; directives
?: ReadonlyArray<DirectiveNodeProps | DirectiveNode>; name
: NameNodeProps | NameNode; type
: TypeNodeProps | GQL.TypeNode }, string> = new Crud({parent: this.node,key: 'fields',api: Api.inputValueDefinitionApi,factory: Ast.inputValueDefinitionNode,matcher: (node): Fieldname => node.name.value,})
Protected node
Methods
createField
- createField(props: InputValueDefinitionNode | Ast.InputValueDefinitionNodeProps): this
-
Parameters
-
props: InputValueDefinitionNode | Ast.InputValueDefinitionNodeProps
Returns this
getField
-
Parameters
getFieldDefaultValue
-
Parameters
Returns ValueApi | undefined
getFieldType
-
Parameters
getFieldnames
-
getFields
-
getFieldsByTypename
-
Parameters
hasField
-
Parameters
Returns boolean
removeField
-
Parameters
Returns this
setFieldDefualtValue
- setFieldDefualtValue(fieldname: Fieldname, props: GQL.ValueNode): this
-
Parameters
Returns this
setFieldType
- setFieldType(fieldname: Fieldname, props: GQL.TypeNode | Ast.TypeNodeProps): this
-
Parameters
-
-
props: GQL.TypeNode | Ast.TypeNodeProps
Returns this
updateField
- updateField(fieldname: Fieldname, props: Partial<InputValueDefinitionNode | Ast.InputValueDefinitionNodeProps>): this
-
Parameters
-
-
props: Partial<InputValueDefinitionNode | Ast.InputValueDefinitionNodeProps>
Returns this
upsertField
- upsertField(props: InputValueDefinitionNode | Ast.InputValueDefinitionNodeProps): this
-
Parameters
-
props: InputValueDefinitionNode | Ast.InputValueDefinitionNodeProps
Returns this