Skip to main content

ExampleModel

@gca_object_type

An example model that demonstrates all the possible field types.

1
@gca_object_type(
2
internalName: "com.brightspot.docs.graphql.example.docs.ExampleModel"
3
embedded: false
4
id: "ea936414-9454-37f9-9fed-848014938adf"
5
abstract: false
6
)
1
type ExampleModel implements RecordEntry, Record, Recordable, RecordMutationEntry, PathsField, Content {
2
_id: ID
3
_label: String
4
_globals: Globals!
5
_raw(
6
path: String
7
): Json
8
_state(
9
path: String
10
): Json @deprecated
11
_urls: URLs!
12
exampleString: String
13
exampleRichTextString: RichText
14
exampleInteger: Int!
15
exampleBoxedInteger: Int
16
exampleLong: Long!
17
exampleBoxedLong: Long
18
exampleFloat: Float!
19
exampleBoxedFloat: Float
20
exampleDouble: Float!
21
exampleBoxedDouble: Float
22
exampleBoolean: Boolean!
23
exampleBoxedBoolean: Boolean
24
exampleEnum: ExampleEnum
25
exampleLocale: Locale
26
exampleDate: Date
27
exampleInstant: Instant
28
exampleOffsetDateTime: OffsetDateTime
29
exampleOffsetTime: OffsetTime
30
exampleLocalDateTime: LocalDateTime
31
exampleLocalDate: LocalDate
32
exampleLocalTime: LocalTime
33
exampleZoneOffset: ZoneOffset
34
exampleZoneId: ZoneId
35
exampleZonedDateTime: ZonedDateTime
36
exampleDuration: Duration
37
examplePeriod: Period
38
exampleYear: Year
39
exampleYearMonth: YearMonth
40
exampleMonthDay: MonthDay
41
exampleURL: URL
42
exampleURI: URI
43
exampleFile: StorageItem
44
exampleReferenceModel: RecordRef
45
exampleReferenceInterface: RecordRef
46
exampleEmbeddedModel: ExampleEmbeddedModel
47
exampleEmbeddedAbstractParentModel: ExampleEmbeddedAbstractParentModel
48
exampleUUID: UUID
49
exampleLocation: GeoPoint
50
exampleRegion: GeoAreaType
51
exampleMap: MapOfJson
52
exampleObject: Json
53
ExampleModelMod: ExampleModelMod!
54
}

Directives

gca_object_type

1
@gca_object_type(
2
internalName: "com.brightspot.docs.graphql.example.docs.ExampleModel"
3
embedded: false
4
id: "ea936414-9454-37f9-9fed-848014938adf"
5
abstract: false
6
)

Fields

_id ● ID scalar common

The unique ID of the Record. Corresponds to the Java method Record#getId and State#getId.

_label ● String scalar common

The display name of the Record instance. Corresponds to the Java methods Record#getLabel and State#getLabel.

_globals ● Globals! non-null object common

Contains global Modification fields for this Record instance.

_raw ● Json scalar common

Contains raw State JSON for this Record instance. The same as invoking getState().getSimpleValues();

path ● String scalar common

Restricts the returned JSON to the specified path within the record’s state.

_urls ● URLs! non-null object common

exampleString ● String scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleString"
4
embedded: false
5
)

exampleRichTextString ● RichText object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleRichTextString"
4
embedded: false
5
)

exampleInteger ● Int! non-null scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleInteger"
4
embedded: false
5
)

exampleBoxedInteger ● Int scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleBoxedInteger"
4
embedded: false
5
)

exampleLong ● Long! non-null scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleLong"
4
embedded: false
5
)

exampleBoxedLong ● Long scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleBoxedLong"
4
embedded: false
5
)

exampleFloat ● Float! non-null scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleFloat"
4
embedded: false
5
)

exampleBoxedFloat ● Float scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleBoxedFloat"
4
embedded: false
5
)

exampleDouble ● Float! non-null scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleDouble"
4
embedded: false
5
)

exampleBoxedDouble ● Float scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleBoxedDouble"
4
embedded: false
5
)

exampleBoolean ● Boolean! non-null scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleBoolean"
4
embedded: false
5
)

exampleBoxedBoolean ● Boolean scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleBoxedBoolean"
4
embedded: false
5
)

exampleEnum ● ExampleEnum enum common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleEnum"
4
embedded: false
5
)

exampleLocale ● Locale scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleLocale"
4
embedded: false
5
)

exampleDate ● Date scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleDate"
4
embedded: false
5
)

exampleInstant ● Instant scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleInstant"
4
embedded: false
5
)

exampleOffsetDateTime ● OffsetDateTime scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleOffsetDateTime"
4
embedded: false
5
)

exampleOffsetTime ● OffsetTime scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleOffsetTime"
4
embedded: false
5
)

exampleLocalDateTime ● LocalDateTime scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleLocalDateTime"
4
embedded: false
5
)

exampleLocalDate ● LocalDate scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleLocalDate"
4
embedded: false
5
)

exampleLocalTime ● LocalTime scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleLocalTime"
4
embedded: false
5
)

exampleZoneOffset ● ZoneOffset scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleZoneOffset"
4
embedded: false
5
)

exampleZoneId ● ZoneId scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleZoneId"
4
embedded: false
5
)

exampleZonedDateTime ● ZonedDateTime scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleZonedDateTime"
4
embedded: false
5
)

exampleDuration ● Duration scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleDuration"
4
embedded: false
5
)

examplePeriod ● Period scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "examplePeriod"
4
embedded: false
5
)

exampleYear ● Year scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleYear"
4
embedded: false
5
)

exampleYearMonth ● YearMonth scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleYearMonth"
4
embedded: false
5
)

exampleMonthDay ● MonthDay scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleMonthDay"
4
embedded: false
5
)

exampleURL ● URL scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleURL"
4
embedded: false
5
)

exampleURI ● URI scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleURI"
4
embedded: false
5
)

exampleFile ● StorageItem object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleFile"
4
embedded: false
5
)

exampleReferenceModel ● RecordRef object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleReferenceModel"
4
embedded: false
5
)

exampleReferenceInterface ● RecordRef object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleReferenceInterface"
4
embedded: false
5
)

exampleEmbeddedModel ● ExampleEmbeddedModel object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleEmbeddedModel"
4
embedded: true
5
)

exampleEmbeddedAbstractParentModel ● ExampleEmbeddedAbstractParentModel interface common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleEmbeddedAbstractParentModel"
4
embedded: true
5
)

exampleUUID ● UUID scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleUUID"
4
embedded: false
5
)

exampleLocation ● GeoPoint object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleLocation"
4
embedded: false
5
)

exampleRegion ● GeoAreaType object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleRegion"
4
embedded: false
5
)

exampleMap ● MapOfJson object common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleMap"
4
embedded: false
5
)

exampleObject ● Json scalar common @gca_object_field

Applied directive:

1
@gca_object_field(
2
indexed: false
3
internalName: "exampleObject"
4
embedded: false
5
)

ExampleModelMod ● ExampleModelMod! non-null object common

Hide deprecated

_state ● Json deprecated scalar common

DEPRECATED

Use [_raw] instead. For removal in 5.0!

Contains raw State JSON for this Record instance. The same as invoking getState().getSimpleValues();

path ● String scalar common

Restricts the returned JSON to the specified path within the record’s state.

Interfaces

RecordEntry interface common

Record interface common

Recordable interface common

The super interface for all types backed by data models, e.g. Java classes that implement Recordable. This interface declares a single _id field containing the UUID of the record. A corresponding _type field is intentionally omitted as it can be derived programmatically from the built-in GraphQL __typename field. Each GraphQL type that implements this interface will be annotated with the @gca_object_type directive which contains the backing data model's type ID.

RecordMutationEntry interface common

PathsField interface common

Content interface common @gca_object_type

Represents a generic content.

1
@gca_object_type(
2
internalName: "com.psddev.cms.db.Content"
3
embedded: false
4
id: "ef5b6d18-7ddc-3eac-b655-cbbd126756d5"
5
abstract: true
6
)