Contains the methods to build an entity.

Type Parameters

Hierarchy

  • EntityBuilder

Constructors

Properties

Methods

Constructors

  • Type Parameters

    • EntityT extends EntityBase<EntityT>

    • DeSerializersT extends DeSerializers<any, any, any, any, any, any, any, any, any, any, any, any, any, any, DeSerializersT>

    Parameters

    • _entityApi: EntityApi<EntityT, DeSerializersT>

    Returns EntityBuilder<EntityT, DeSerializersT>

Properties

_entity: EntityT
_entityApi: EntityApi<EntityT, DeSerializersT>

Methods

  • Builds the entity.

    Returns

    The entity.

    Returns EntityT

  • Builds an entity from JSON representation. If you have obtained the JSON object as a request payload use the entityDeserializer methods. Note that fields not mappable to a field in the target entity are silently ignored.

    Returns

    EntityBase constructed from JSON representation.

    Parameters

    • json: FromJsonType<EntityT>

      Representation of the entity in JSON format.

    Returns EntityT

  • Sets the custom fields for the entity.

    Returns

    The entity builder itself for method chaining.

    Parameters

    • customFields: Record<string, any>

      The custom fields you want to add.

    Returns EntityBuilder<EntityT, DeSerializersT>

Copyright Ⓒ 2023 SAP SE or an SAP affiliate company. All rights reserved.