Skip to main content

Preview

@gca_object_type

Represents a preview of an object.

1
@gca_object_type(
2
internalName: "com.psddev.cms.db.Preview"
3
embedded: false
4
id: "c67301a3-093e-3745-9c3d-8e4999d85810"
5
abstract: false
6
)
1
type Preview implements Record, Recordable {
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
createDate: Date
12
objectType: ObjectType
13
objectId: UUID
14
objectValues: MapOfJson
15
site: RecordRef
16
context: String
17
defaultPreviewType: UUID
18
overlay: Overlay
19
overlayProvider: OverlayProvider
20
options: MapOfJson
21
expiration: Date
22
}

Directives

gca_object_type

1
@gca_object_type(
2
internalName: "com.psddev.cms.db.Preview"
3
embedded: false
4
id: "c67301a3-093e-3745-9c3d-8e4999d85810"
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.

createDate ● Date scalar common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

objectType ● ObjectType object common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

objectId ● UUID scalar common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

objectValues ● MapOfJson object common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

site ● RecordRef object common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

context ● String scalar common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

defaultPreviewType ● UUID scalar common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

overlay ● Overlay interface common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

overlayProvider ● OverlayProvider interface common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

options ● MapOfJson object common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

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

expiration ● Date scalar common @gca_getter @gca_object_field

Applied directive:

1
@gca_getter

Applied directive:

1
@gca_object_field(
2
indexed: true
3
internalName: "expiration"
4
embedded: false
5
)
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

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.

Member Of