Skip to main content

@terascope/data-types / types/base-type

types/base-type

Classes​

ClassDescription
defaultThe abstract base class every field type extends. It captures a single field's identity (field name, its DataTypeFieldConfig, and the data-type version) and defines the contract for converting that field into each supported output format.

Interfaces​

InterfaceDescription
IBaseType-

Type Aliases​

ToGraphQLOptions​

ToGraphQLOptions = object

Defined in: data-types/src/types/base-type.ts:14

Options controlling how a field is rendered into GraphQL.

Properties​

includePrivate?​

optional includePrivate?: boolean

Defined in: data-types/src/types/base-type.ts:17

isInput?​

optional isInput?: boolean

Defined in: data-types/src/types/base-type.ts:16

typeName?​

optional typeName?: string

Defined in: data-types/src/types/base-type.ts:15

useSnakeCase?​

optional useSnakeCase?: boolean

Defined in: data-types/src/types/base-type.ts:18

Functions​

formatGQLType()​

formatGQLType(type, desc?): string

Defined in: data-types/src/types/base-type.ts:104

Prefix a GraphQL type/field line with its formatted description, when present.

Parameters​

ParameterType
typestring
desc?string

Returns​

string