Skip to main content

@ObjectModel

BETA This annotation is beta and should be reviewed for completion and correctness.

Introduction

The object model captures definitions of structural as well as transactional related aspects of the business data model.

Schema Definitions

Annotations Overview

AnnotationScopeDescription
@ObjectModel.compositionRootEntityEntity is the root of a compositional hierarchy.
@ObjectModel.representativeKeyEntity, ServiceIn case of multiple key elements: key element which represents the entity (in the sense that the entity itself is the list of values for this key element)
@ObjectModel.semanticKeyEntityThe entity contains element(s) which shall be used to display the key in UIs (instead of the technical key).
@ObjectModel.customType, Entity, ServiceIndicates whether the annotated element or entity is a custom element.
If set to true, it is a custom element (field, entity, service, etc.).
If undefined or set to false, it is not defined whether it is a custom element.

If applied to an entity or service, everything that it contains is also considered custom.
@ObjectModel.modelingPatternEntity, ServiceThe property declares the modeling pattern applied in this entity definition.
@ObjectModel.supportedCapabilitiesEntity, ServiceThe property declares the supported usage type for this entity in the context of consuming data models.
@ObjectModel.foreignKey.associationTypeThe element is of type cds.Association which points to the list of values.

Use only for service internal associations. For cross service associations, use the @EntityRelationship Vocabulary instead.
@ObjectModel.text.elementTypeThe property contains element(s) containing a text for the annotated (id)element
@ObjectModel.text.associationTypeThe element is of type cds.association, which points to an entity containing (language-dependent) texts for the annotated (id) element
@ObjectModel.tenantWideUniqueNameEntityUnique technical name of the entity within the tenant / isolation context it is deployed to.
This may be used as a hint for database table names and help to keep them short enough.

Once chosen the technical name ID MUST be kept stable (immutable).
@ObjectModel.usageType.sizeCategoryEntityThe size category enables the consumer to judge the possible result data set size.
It is a pure estimation at design time while modeling the entity what the data set size would be at runtime.
It reflects the set of data which has to be searched through to compute for example a count(*) of the data.

The labels correspond to the following size categories (expected number of rows at production customers):
- S: less than 1000
- M: less than 100.000
- L: less than 10.000.000
- XL: less than 100.000.000
- XXL: more than 100.000.000

@ObjectModel.compositionRoot

Entity is the root of a compositional hierarchy.

Scope: Entity
Extending: EntityDefinition
Type: boolean
Default Value: true

@ObjectModel.representativeKey

In case of multiple key elements: key element which represents the entity (in the sense that the entity itself is the list of values for this key element)

Scope: Entity, Service
Extending: EntityDefinition, ServiceDefinition
External Type: Element Reference

@ObjectModel.semanticKey

The entity contains element(s) which shall be used to display the key in UIs (instead of the technical key).

Scope: Entity
Extending: EntityDefinition
Type: Array<Element Reference>

@ObjectModel.custom

Indicates whether the annotated element or entity is a custom element. If set to true, it is a custom element (field, entity, service, etc.). If undefined or set to false, it is not defined whether it is a custom element.

If applied to an entity or service, everything that it contains is also considered custom.

Scope: Type, Entity, Service
Extending: BooleanType, StringType, LargeStringType, IntegerType, Integer64Type, DecimalType, DoubleType, DateType, TimeType, DateTimeType, TimestampType, UUIDType, AssociationType, CompositionType, CustomType, TypeDefinition, BooleanTypeDefinition, StringTypeDefinition, LargeStringTypeDefinition, IntegerTypeDefinition, Integer64TypeDefinition, DecimalTypeDefinition, DoubleTypeDefinition, DateTypeDefinition, TimeTypeDefinition, DateTimeTypeDefinition, TimestampTypeDefinition, UUIDTypeDefinition, AssociationTypeDefinition, CompositionTypeDefinition, EntityDefinition, ServiceDefinition
Type: boolean

@ObjectModel.modelingPattern

The property declares the modeling pattern applied in this entity definition.

Scope: Entity, Service
Extending: EntityDefinition, ServiceDefinition
Type: Object(#)

PropertyTypeDescription
#
MANDATORY
string
Provide the value in { "#": "<value>" } enum notation.
Allowed Values:
  • "DATA_STRUCTURE"
  • "LANGUAGE_DEPENDENT_TEXT"
  • "UNIT_CONVERSION_RATE"
  • "VALUE_HELP_PROVIDER"
  • "COLLECTIVE_VALUE_HELP"
  • "DERIVATION_FUNCTION"
  • "PARENT_CHILD_HIERARCHY_NODE_PROVIDER"
  • "ENTERPRISE_SEARCH_PROVIDER"
  • "TRANSACTIONAL_INTERFACE"
  • "TRANSACTIONAL_QUERY"
  • "ANALYTICAL_QUERY"
  • "ANALYTICAL_DOCUMENT_STORE"
  • "ANALYTICAL_CUBE"
  • "ANALYTICAL_DIMENSION"
  • "ANALYTICAL_FACT"
  • "ANALYTICAL_PARENT_CHILD_HIERARCHY_NODE"
  • "ANALYTICAL_KPI"
  • "OUTPUT_FORM_DATA_PROVIDER"
  • "OUTPUT_EMAIL_DATA_PROVIDER"
  • "OUTPUT_PARAMETER_DETERMINATION_DATA_SOURCE"
  • "SITUATION_ANCHOR"
  • "SITUATION_TRIGGER"
  • "SITUATION_DATACONTEXT"
  • "EXTERNAL_DATA_PROVIDER"
  • "NONE"
Example Values:
{
"#": "DATA_STRUCTURE"
}

@ObjectModel.supportedCapabilities

The property declares the supported usage type for this entity in the context of consuming data models.

Scope: Entity, Service
Extending: EntityDefinition, ServiceDefinition
Type: Array<Supported Capabilities Enum Value>

@ObjectModel.foreignKey.association

The element is of type cds.Association which points to the list of values.

Use only for service internal associations. For cross service associations, use the @EntityRelationship Vocabulary instead.

Scope: Type
Extending: BooleanType, StringType, LargeStringType, IntegerType, Integer64Type, DecimalType, DoubleType, DateType, TimeType, DateTimeType, TimestampType, UUIDType, AssociationType, CompositionType, CustomType, TypeDefinition, BooleanTypeDefinition, StringTypeDefinition, LargeStringTypeDefinition, IntegerTypeDefinition, Integer64TypeDefinition, DecimalTypeDefinition, DoubleTypeDefinition, DateTypeDefinition, TimeTypeDefinition, DateTimeTypeDefinition, TimestampTypeDefinition, UUIDTypeDefinition, AssociationTypeDefinition, CompositionTypeDefinition
External Type: Element Reference

@ObjectModel.text.element

The property contains element(s) containing a text for the annotated (id)element

Scope: Type
Extending: BooleanType, StringType, LargeStringType, IntegerType, Integer64Type, DecimalType, DoubleType, DateType, TimeType, DateTimeType, TimestampType, UUIDType, AssociationType, CompositionType, CustomType, TypeDefinition, BooleanTypeDefinition, StringTypeDefinition, LargeStringTypeDefinition, IntegerTypeDefinition, Integer64TypeDefinition, DecimalTypeDefinition, DoubleTypeDefinition, DateTypeDefinition, TimeTypeDefinition, DateTimeTypeDefinition, TimestampTypeDefinition, UUIDTypeDefinition, AssociationTypeDefinition, CompositionTypeDefinition
Type: Array<Element Reference>

Example Values:
[
"BillingDocumentTypeName"
]

@ObjectModel.text.association

The element is of type cds.association, which points to an entity containing (language-dependent) texts for the annotated (id) element

Scope: Type
Extending: BooleanType, StringType, LargeStringType, IntegerType, Integer64Type, DecimalType, DoubleType, DateType, TimeType, DateTimeType, TimestampType, UUIDType, AssociationType, CompositionType, CustomType, TypeDefinition, BooleanTypeDefinition, StringTypeDefinition, LargeStringTypeDefinition, IntegerTypeDefinition, Integer64TypeDefinition, DecimalTypeDefinition, DoubleTypeDefinition, DateTypeDefinition, TimeTypeDefinition, DateTimeTypeDefinition, TimestampTypeDefinition, UUIDTypeDefinition, AssociationTypeDefinition, CompositionTypeDefinition
External Type: Element Reference

@ObjectModel.tenantWideUniqueName

Unique technical name of the entity within the tenant / isolation context it is deployed to. This may be used as a hint for database table names and help to keep them short enough.

Once chosen the technical name ID MUST be kept stable (immutable).

Scope: Entity
Extending: EntityDefinition
Type: string
Maximum Length: 120

@ObjectModel.usageType.sizeCategory

The size category enables the consumer to judge the possible result data set size. It is a pure estimation at design time while modeling the entity what the data set size would be at runtime. It reflects the set of data which has to be searched through to compute for example a count(*) of the data.

The labels correspond to the following size categories (expected number of rows at production customers):

  • S: less than 1000
  • M: less than 100.000
  • L: less than 10.000.000
  • XL: less than 100.000.000
  • XXL: more than 100.000.000

Scope: Entity
Extending: EntityDefinition
Type: Object(#)

PropertyTypeDescription
#
MANDATORY
string
Provide the value in { "#": "<value>" } enum notation.
Allowed Values:
  • "S"
  • "M"
  • "L"
  • "XL"
  • "XXL"
Example Values:
{
"#": "XL"
}

Supported Capabilities Enum Value

Type: Object(#)

PropertyTypeDescription
#
MANDATORY
string
The entry declares one supported usage type.
Allowed Values:
  • "SQL_DATA_SOURCE"
  • "CDS_MODELING_DATA_SOURCE"
  • "CDS_MODELING_ASSOCIATION_TARGET"
  • "DATA_STRUCTURE"
  • "LANGUAGE_DEPENDENT_TEXT"
  • "UNIT_CONVERSION_RATE"
  • "VALUE_HELP_PROVIDER"
  • "COLLECTIVE_VALUE_HELP"
  • "EXTRACTION_DATA_SOURCE"
  • "DERIVATION_FUNCTION"
  • "PARENT_CHILD_HIERARCHY_NODE_PROVIDER"
  • "SEARCHABLE_ENTITY"
  • "ENTERPRISE_SEARCH_PROVIDER"
  • "TRANSACTIONAL_PROVIDER"
  • "ANALYTICAL_QUERY"
  • "ANALYTICAL_DOCUMENT_STORE"
  • "ANALYTICAL_DIMENSION"
  • "ANALYTICAL_PROVIDER"
  • "ANALYTICAL_PARENT_CHILD_HIERARCHY_NODE"
  • "ANALYTICAL_KPI"
  • "OUTPUT_FORM_DATA_PROVIDER"
  • "OUTPUT_EMAIL_DATA_PROVIDER"
  • "OUTPUT_PARAMETER_DETERMINATION_DATA_SOURCE"
  • "SITUATION_ANCHOR"
  • "SITUATION_TRIGGER"
  • "SITUATION_DATACONTEXT"
  • "KEY_USER_COPYING_TEMPLATE"
  • "EXTERNAL_DATA_PROVIDER"
  • "ODM_COMPLIANT_PROVIDER"
  • "UI_PROVIDER_PROJECTION_SOURCE"