Options
All
  • Public
  • Public/Protected
  • All
Menu

This class represents the entity "MaterialCoverages" of service "API_MRP_MATERIALS_SRV_01". This service is part of the following communication scenarios: Production Planning Integration (SAP_COM_0104). See https://api.sap.com/api/API_MRP_MATERIALS_SRV_01 for more information.

Hierarchy

  • Entity
    • MaterialCoverages

Implements

Index

Constructors

Properties

Methods

Constructors

constructor

  • Returns MaterialCoverages

Properties

Protected _customFields

_customFields: MapType<any>

A mapper representing custom fields in an entity. Custom fields are represented by their field names and the corresponding values. A custom field can be added or updated using setCustomField method.

Protected _versionIdentifier

_versionIdentifier: string

The current ETag version of the entity in the remote system. The ETag identified the version of the in the remote system. It will be automatically set in the "if-match" header of update requests and can be set as a custom header for delete requests. When no ETag is provided by the remote system the value of this variable defaults to "*".

Optional daysOfSupplyDuration

daysOfSupplyDuration: number

Days Of Supply Duration.

nullable

hasAcceptedShortage

hasAcceptedShortage: string

Has Accepted Shortage. Maximum length: 1.

material

material: string

Material. Maximum length: 40.

materialBaseUnit

materialBaseUnit: string

Material Base Unit. Maximum length: 3.

materialExternalId

materialExternalId: string

Material External Id. Maximum length: 40.

materialName

materialName: string

Material Name. Maximum length: 40.

Optional materialReplnmtLeadDurnEndDate

materialReplnmtLeadDurnEndDate: Moment

UTC Time Stamp in Short Form (YYYYMMDDhhmmss). The UTC timestamp is the date and time relative to the UTC (Universal coordinated time). To normalize local times in a UTC time stamp and make them comparable, they must be converted using their time zone and the ABAP command convert.Although the time zone for the conversion can be fetched from customizing or master data, you should save it redundantly.The internal structure of the UTC time stamp is logically divided into a date and time part in packed number format <YYYYMMDDhhmmss>. There is also a high resolution UTC time stamp (10^-7 seconds).

nullable

materialShortageDefinitionName

materialShortageDefinitionName: string

Material Shortage Definition Name. Maximum length: 40.

materialShortageDuration

materialShortageDuration: number

Material Shortage Duration.

materialShortageDurnInWorkdays

materialShortageDurnInWorkdays: number

Material Shortage Durn In Workdays.

Optional materialShortageEndDate

materialShortageEndDate: Moment

UTC Time Stamp in Short Form (YYYYMMDDhhmmss). The UTC timestamp is the date and time relative to the UTC (Universal coordinated time). To normalize local times in a UTC time stamp and make them comparable, they must be converted using their time zone and the ABAP command convert.Although the time zone for the conversion can be fetched from customizing or master data, you should save it redundantly.The internal structure of the UTC time stamp is logically divided into a date and time part in packed number format <YYYYMMDDhhmmss>. There is also a high resolution UTC time stamp (10^-7 seconds).

nullable

materialShortageProfile

materialShortageProfile: string

Material Shortage Profile. Maximum length: 12.

materialShortageProfileCount

materialShortageProfileCount: string

Material Shortage Profile Count. Maximum length: 3.

Optional materialShortageQuantity

materialShortageQuantity: BigNumber

Material Shortage Quantity.

nullable

Optional materialShortageStartDate

materialShortageStartDate: Moment

UTC Time Stamp in Short Form (YYYYMMDDhhmmss). The UTC timestamp is the date and time relative to the UTC (Universal coordinated time). To normalize local times in a UTC time stamp and make them comparable, they must be converted using their time zone and the ABAP command convert.Although the time zone for the conversion can be fetched from customizing or master data, you should save it redundantly.The internal structure of the UTC time stamp is logically divided into a date and time part in packed number format <YYYYMMDDhhmmss>. There is also a high resolution UTC time stamp (10^-7 seconds).

nullable

mrpArea

mrpArea: string

Mrp Area. Maximum length: 10.

mrpAreaText

mrpAreaText: string

Mrp Area Text. Maximum length: 40.

mrpController

mrpController: string

Mrp Controller. Maximum length: 3.

mrpControllerName

mrpControllerName: string

Mrp Controller Name. Maximum length: 18.

mrpPlanningSegmentNumber

mrpPlanningSegmentNumber: string

Mrp Planning Segment Number. Maximum length: 20.

mrpPlanningSegmentType

mrpPlanningSegmentType: string

Mrp Planning Segment Type. Maximum length: 2.

mrpPlanningSegmentTypeDesc

mrpPlanningSegmentTypeDesc: string

Mrp Planning Segment Type Desc. Maximum length: 6.

mrpPlant

mrpPlant: string

Mrp Plant. Maximum length: 4.

mrpPlantName

mrpPlantName: string

Mrp Plant Name. Maximum length: 30.

mrpSafetyDuration

mrpSafetyDuration: string

Mrp Safety Duration. Maximum length: 2.

Optional mrpSafetyDurationEndDate

mrpSafetyDurationEndDate: Moment

UTC Time Stamp in Short Form (YYYYMMDDhhmmss). The UTC timestamp is the date and time relative to the UTC (Universal coordinated time). To normalize local times in a UTC time stamp and make them comparable, they must be converted using their time zone and the ABAP command convert.Although the time zone for the conversion can be fetched from customizing or master data, you should save it redundantly.The internal structure of the UTC time stamp is logically divided into a date and time part in packed number format <YYYYMMDDhhmmss>. There is also a high resolution UTC time stamp (10^-7 seconds).

nullable

Protected remoteState

remoteState: object

The remote state of the entity. Remote state refers to the last known state of the entity on the remote system from which it has been retrieved or to which it has been posted. It is stored as map, where the keys are stored in the format of VDM properties.

Type declaration

  • [keys: string]: any

Optional timeHorizonInDays

timeHorizonInDays: number

Signed INT2 / Edm.int16.

nullable

versionIdentifier

versionIdentifier: string

ETag version identifier accessor.

returns

The ETag version identifier of the retrieved entity, returns undefined if not retrieved

Static ALL_FIELDS

ALL_FIELDS: AllFields<MaterialCoverages> = new AllFields('*', MaterialCoverages)

All fields selector.

Static DAYS_OF_SUPPLY_DURATION

DAYS_OF_SUPPLY_DURATION: NumberField<MaterialCoverages> = new NumberField('DaysOfSupplyDuration', MaterialCoverages, 'Edm.Int32')

Static representation of the daysOfSupplyDuration property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static HAS_ACCEPTED_SHORTAGE

HAS_ACCEPTED_SHORTAGE: StringField<MaterialCoverages> = new StringField('HasAcceptedShortage', MaterialCoverages, 'Edm.String')

Static representation of the hasAcceptedShortage property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL

MATERIAL: StringField<MaterialCoverages> = new StringField('Material', MaterialCoverages, 'Edm.String')

Static representation of the material property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_BASE_UNIT

MATERIAL_BASE_UNIT: StringField<MaterialCoverages> = new StringField('MaterialBaseUnit', MaterialCoverages, 'Edm.String')

Static representation of the materialBaseUnit property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_EXTERNAL_ID

MATERIAL_EXTERNAL_ID: StringField<MaterialCoverages> = new StringField('MaterialExternalID', MaterialCoverages, 'Edm.String')

Static representation of the materialExternalId property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_NAME

MATERIAL_NAME: StringField<MaterialCoverages> = new StringField('MaterialName', MaterialCoverages, 'Edm.String')

Static representation of the materialName property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_REPLNMT_LEAD_DURN_END_DATE

MATERIAL_REPLNMT_LEAD_DURN_END_DATE: DateField<MaterialCoverages> = new DateField('MaterialReplnmtLeadDurnEndDate', MaterialCoverages, 'Edm.DateTime')

Static representation of the materialReplnmtLeadDurnEndDate property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_DEFINITION_NAME

MATERIAL_SHORTAGE_DEFINITION_NAME: StringField<MaterialCoverages> = new StringField('MaterialShortageDefinitionName', MaterialCoverages, 'Edm.String')

Static representation of the materialShortageDefinitionName property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_DURATION

MATERIAL_SHORTAGE_DURATION: NumberField<MaterialCoverages> = new NumberField('MaterialShortageDuration', MaterialCoverages, 'Edm.Int32')

Static representation of the materialShortageDuration property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_DURN_IN_WORKDAYS

MATERIAL_SHORTAGE_DURN_IN_WORKDAYS: NumberField<MaterialCoverages> = new NumberField('MaterialShortageDurnInWorkdays', MaterialCoverages, 'Edm.Int32')

Static representation of the materialShortageDurnInWorkdays property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_END_DATE

MATERIAL_SHORTAGE_END_DATE: DateField<MaterialCoverages> = new DateField('MaterialShortageEndDate', MaterialCoverages, 'Edm.DateTime')

Static representation of the materialShortageEndDate property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_PROFILE

MATERIAL_SHORTAGE_PROFILE: StringField<MaterialCoverages> = new StringField('MaterialShortageProfile', MaterialCoverages, 'Edm.String')

Static representation of the materialShortageProfile property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_PROFILE_COUNT

MATERIAL_SHORTAGE_PROFILE_COUNT: StringField<MaterialCoverages> = new StringField('MaterialShortageProfileCount', MaterialCoverages, 'Edm.String')

Static representation of the materialShortageProfileCount property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_QUANTITY

MATERIAL_SHORTAGE_QUANTITY: BigNumberField<MaterialCoverages> = new BigNumberField('MaterialShortageQuantity', MaterialCoverages, 'Edm.Decimal')

Static representation of the materialShortageQuantity property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MATERIAL_SHORTAGE_START_DATE

MATERIAL_SHORTAGE_START_DATE: DateField<MaterialCoverages> = new DateField('MaterialShortageStartDate', MaterialCoverages, 'Edm.DateTime')

Static representation of the materialShortageStartDate property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_AREA

MRP_AREA: StringField<MaterialCoverages> = new StringField('MRPArea', MaterialCoverages, 'Edm.String')

Static representation of the mrpArea property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_AREA_TEXT

MRP_AREA_TEXT: StringField<MaterialCoverages> = new StringField('MRPAreaText', MaterialCoverages, 'Edm.String')

Static representation of the mrpAreaText property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_CONTROLLER

MRP_CONTROLLER: StringField<MaterialCoverages> = new StringField('MRPController', MaterialCoverages, 'Edm.String')

Static representation of the mrpController property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_CONTROLLER_NAME

MRP_CONTROLLER_NAME: StringField<MaterialCoverages> = new StringField('MRPControllerName', MaterialCoverages, 'Edm.String')

Static representation of the mrpControllerName property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_PLANNING_SEGMENT_NUMBER

MRP_PLANNING_SEGMENT_NUMBER: StringField<MaterialCoverages> = new StringField('MRPPlanningSegmentNumber', MaterialCoverages, 'Edm.String')

Static representation of the mrpPlanningSegmentNumber property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_PLANNING_SEGMENT_TYPE

MRP_PLANNING_SEGMENT_TYPE: StringField<MaterialCoverages> = new StringField('MRPPlanningSegmentType', MaterialCoverages, 'Edm.String')

Static representation of the mrpPlanningSegmentType property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_PLANNING_SEGMENT_TYPE_DESC

MRP_PLANNING_SEGMENT_TYPE_DESC: StringField<MaterialCoverages> = new StringField('MRPPlanningSegmentTypeDesc', MaterialCoverages, 'Edm.String')

Static representation of the mrpPlanningSegmentTypeDesc property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_PLANT

MRP_PLANT: StringField<MaterialCoverages> = new StringField('MRPPlant', MaterialCoverages, 'Edm.String')

Static representation of the mrpPlant property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_PLANT_NAME

MRP_PLANT_NAME: StringField<MaterialCoverages> = new StringField('MRPPlantName', MaterialCoverages, 'Edm.String')

Static representation of the mrpPlantName property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_SAFETY_DURATION

MRP_SAFETY_DURATION: StringField<MaterialCoverages> = new StringField('MRPSafetyDuration', MaterialCoverages, 'Edm.String')

Static representation of the mrpSafetyDuration property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static MRP_SAFETY_DURATION_END_DATE

MRP_SAFETY_DURATION_END_DATE: DateField<MaterialCoverages> = new DateField('MRPSafetyDurationEndDate', MaterialCoverages, 'Edm.DateTime')

Static representation of the mrpSafetyDurationEndDate property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static TIME_HORIZON_IN_DAYS

TIME_HORIZON_IN_DAYS: NumberField<MaterialCoverages> = new NumberField('TimeHorizonInDays', MaterialCoverages, 'Edm.Int16')

Static representation of the timeHorizonInDays property for query construction. Use to reference this property in query operations such as 'select' in the fluent request API.

Static _allFields

_allFields: Array<StringField<MaterialCoverages> | NumberField<MaterialCoverages> | DateField<MaterialCoverages> | BigNumberField<MaterialCoverages>> = [MaterialCoverages.MATERIAL,MaterialCoverages.MATERIAL_SHORTAGE_PROFILE,MaterialCoverages.MATERIAL_SHORTAGE_PROFILE_COUNT,MaterialCoverages.MRP_AREA,MaterialCoverages.MRP_PLANNING_SEGMENT_NUMBER,MaterialCoverages.MRP_PLANNING_SEGMENT_TYPE,MaterialCoverages.MRP_PLANT,MaterialCoverages.HAS_ACCEPTED_SHORTAGE,MaterialCoverages.TIME_HORIZON_IN_DAYS,MaterialCoverages.MATERIAL_SHORTAGE_DURATION,MaterialCoverages.MATERIAL_SHORTAGE_DURN_IN_WORKDAYS,MaterialCoverages.MRP_CONTROLLER,MaterialCoverages.MRP_SAFETY_DURATION,MaterialCoverages.DAYS_OF_SUPPLY_DURATION,MaterialCoverages.MATERIAL_BASE_UNIT,MaterialCoverages.MATERIAL_EXTERNAL_ID,MaterialCoverages.MATERIAL_NAME,MaterialCoverages.MATERIAL_REPLNMT_LEAD_DURN_END_DATE,MaterialCoverages.MATERIAL_SHORTAGE_DEFINITION_NAME,MaterialCoverages.MATERIAL_SHORTAGE_END_DATE,MaterialCoverages.MATERIAL_SHORTAGE_QUANTITY,MaterialCoverages.MATERIAL_SHORTAGE_START_DATE,MaterialCoverages.MRP_AREA_TEXT,MaterialCoverages.MRP_CONTROLLER_NAME,MaterialCoverages.MRP_PLANNING_SEGMENT_TYPE_DESC,MaterialCoverages.MRP_PLANT_NAME,MaterialCoverages.MRP_SAFETY_DURATION_END_DATE]

All fields of the MaterialCoverages entity.

Static _defaultServicePath

_defaultServicePath: string = "/sap/opu/odata/sap/API_MRP_MATERIALS_SRV_01"

Default url path for the according service.

Static _entityName

_entityName: string = "MaterialCoverages"

Technical entity name for MaterialCoverages.

Static _keyFields

_keyFields: Array<Selectable<MaterialCoverages>> = [MaterialCoverages.MATERIAL, MaterialCoverages.MATERIAL_SHORTAGE_PROFILE, MaterialCoverages.MATERIAL_SHORTAGE_PROFILE_COUNT, MaterialCoverages.MRP_AREA, MaterialCoverages.MRP_PLANNING_SEGMENT_NUMBER, MaterialCoverages.MRP_PLANNING_SEGMENT_TYPE, MaterialCoverages.MRP_PLANT]

All key fields of the MaterialCoverages entity.

Static _keys

_keys: object = MaterialCoverages._keyFields.reduce((acc: { [keys: string]: Selectable<MaterialCoverages> }, field: Selectable<MaterialCoverages>) => {acc[field.fieldName] = field;return acc;}, {})

Mapping of all key field names to the respective static field property MaterialCoverages.

Type declaration

Static _serviceName

_serviceName: string = "API_MRP_MATERIALS_SRV_01"
deprecated

Since v1.0.1 Use _defaultServicePath instead. Technical service name for MaterialCoverages.

Methods

Protected getCurrentMapKeys

  • getCurrentMapKeys(): Entity
  • Returns a map of all defined fields in entity to their current values.

    Returns Entity

    Entity with all defined entity fields

getCustomField

  • getCustomField(fieldName: string): any
  • Custom field value getter.

    Parameters

    • fieldName: string

      The name of the custom field

    Returns any

    The value of the corresponding custom field

getCustomFields

  • getCustomFields(): MapType<any>
  • Returns a map that contains all entity custom fields.

    Returns MapType<any>

    A map of all defined custom fields in the entity

getUpdatedCustomFields

  • getUpdatedCustomFields(): MapType<any>
  • Returns all updated custom field properties compared to the last known remote state.

    Returns MapType<any>

    A map containing all updated custom properties, with their new values

getUpdatedProperties

  • getUpdatedProperties(): Entity
  • Returns all changed properties compared to the last known remote state. The returned properties does not include custom fields. Use getUpdatedCustomFields, if updated custom fields are needed.

    Returns Entity

    Entity with all properties that changed

hasCustomField

  • hasCustomField(fieldName: string): boolean
  • Validates whether a custom field exists in the entity.

    Parameters

    • fieldName: string

      The name of the custom field to update

    Returns boolean

    A boolean value, that indicates whether a custom field is defined in entity

initializeCustomFields

  • initializeCustomFields(customFields: MapType<any>): this
  • Sets all retrieved custom fields in entity.

    Parameters

    • customFields: MapType<any>

      Extracted custom fields from a retrieved entity

    Returns this

    A boolean value, that indicates the existence of the field in entity

Protected isConflictingCustomField

  • isConflictingCustomField(customFieldName: string): boolean
  • Validates whether a field name does not conflict with an original field name and thus can be defined as custom fields.

    Parameters

    • customFieldName: string

      Field name to check

    Returns boolean

    Boolean value that describes whether a field name can be defined as custom field

setCustomField

  • setCustomField(fieldName: string, value: any): this
  • Sets a new custom field in the entity or updates it. Throws an error, if the provided custom field name is already defined by an original field in entity.

    Parameters

    • fieldName: string

      The name of the custom field to update

    • value: any

      The value of the field

    Returns this

    The entity itself, to facilitate method chaining

setOrInitializeRemoteState

  • setOrInitializeRemoteState(state?: MapType<any>): this
  • Initializes or sets the remoteState of the entity. This function is called on all read, create and update requests. This function should be called after initializeCustomFields, if custom fields are defined.

    Parameters

    • Optional state: MapType<any>

      State to be set as remote state

    Returns this

    The entity itself, to facilitate method chaining

setVersionIdentifier

  • setVersionIdentifier(etag: string): this
  • Set the ETag version identifier of the retrieved entity.

    Parameters

    • etag: string

      The returned ETag version of the entity

    Returns this

    The entity itself, to facilitate method chaining

toJSON

  • toJSON(): object
  • Overwrites the default toJSON method so that all instance variables as well as all custom fields of the entity are returned.

    Returns object

    An object containing all instance variables + custom fields.

    • [key: string]: any

Static builder

  • Returns an entity builder to construct instances MaterialCoverages.

    Returns EntityBuilderType<MaterialCoverages, MaterialCoveragesType>

    A builder that constructs instances of entity type MaterialCoverages.

Static customField

  • Returns a selectable object that allows the selection of custom field in a get request for the entity MaterialCoverages.

    Parameters

    • fieldName: string

      Name of the custom field to select

    Returns CustomField<MaterialCoverages>

    A builder that constructs instances of entity type MaterialCoverages.

Static Protected customFieldSelector

  • customFieldSelector<EntityT>(fieldName: string, entityConstructor: Constructable<EntityT>): CustomField<EntityT>
  • Type parameters

    • EntityT: Entity

    Parameters

    • fieldName: string
    • entityConstructor: Constructable<EntityT>

    Returns CustomField<EntityT>

Static Protected entityBuilder

  • entityBuilder<EntityT, JsonT>(entityConstructor: Constructable<EntityT, JsonT>): EntityBuilderType<EntityT, JsonT>
  • Type parameters

    • EntityT: Entity

    • JsonT

    Parameters

    • entityConstructor: Constructable<EntityT, JsonT>

    Returns EntityBuilderType<EntityT, JsonT>

Static requestBuilder

  • Returns a request builder to construct requests for operations on the MaterialCoverages entity type.

    Returns MaterialCoveragesRequestBuilder

    A MaterialCoverages request builder.