Class DefaultMaterialDocumentService
- All Implemented Interfaces:
BatchService<MaterialDocumentServiceBatch>,MaterialDocumentService
This service enables you to retrieve and create material documents, for example, to post a goods receipt for a purchase order or to document the transfer of materials between two storage locations. Additionally, the service allows you to cancel existing material documents or single items. It can be consumed by external systems and user interfaces..
Reference: SAP Business Accelerator Hub
Details:
| OData Service: | API_MATERIAL_DOCUMENT_SRV |
| API Version: | 1.2.0 |
| Minimum ERP Version: | 2302 |
| Communication Scenario: | Material Document Integration(SAP_COM_0108) |
| Scope Items: | Core Inventory Management(BMC), Core Inventory Management(OMC) |
| Authentication Methods: | x509 |
| Business Object: | Material Document |
-
Field Summary
Fields inherited from interface com.sap.cloud.sdk.s4hana.datamodel.odata.services.MaterialDocumentService
DEFAULT_SERVICE_PATH -
Constructor Summary
ConstructorsConstructorDescriptionDeprecated.Creates a service usingMaterialDocumentService.DEFAULT_SERVICE_PATHto send the requests. -
Method Summary
Modifier and TypeMethodDescriptionbatch()Deprecated.cancel(String materialDocumentYear, String materialDocument, LocalDateTime postingDate) Deprecated.Creates a fluent helper for the Cancel OData function import.cancelItem(String materialDocumentYear, String materialDocument, String materialDocumentItem, LocalDateTime postingDate) Deprecated.Creates a fluent helper for the CancelItem OData function import.createMaterialDocumentHeader(MaterialDocumentHeader materialDocumentHeader) Deprecated.Create a newMaterialDocumentHeaderentity and save it to the S/4HANA system.Deprecated.Fetch multipleMaterialDocumentHeaderentities.Deprecated.Fetch multipleMaterialDocumentItementities.Deprecated.Fetch multipleSerialNumberMaterialDocumententities.getMaterialDocumentHeaderByKey(String materialDocumentYear, String materialDocument) Deprecated.Fetch a singleMaterialDocumentHeaderentity using key fields.getMaterialDocumentItemByKey(String materialDocumentYear, String materialDocument, String materialDocumentItem) Deprecated.Fetch a singleMaterialDocumentItementity using key fields.getSerialNumberMaterialDocumentByKey(String material, String serialNumber, String materialDocument, String materialDocumentItem, String materialDocumentYear) Deprecated.Fetch a singleSerialNumberMaterialDocumententity using key fields.withServicePath(String servicePath) Deprecated.Overrides the default service path and returns a new service instance with the specified service path.
-
Constructor Details
-
DefaultMaterialDocumentService
public DefaultMaterialDocumentService()Deprecated.Creates a service usingMaterialDocumentService.DEFAULT_SERVICE_PATHto send the requests.
-
-
Method Details
-
withServicePath
Deprecated.Description copied from interface:MaterialDocumentServiceOverrides the default service path and returns a new service instance with the specified service path. Also adjusts the respective entity URLs.- Specified by:
withServicePathin interfaceMaterialDocumentService- Parameters:
servicePath- Service path that will override the default.- Returns:
- A new service instance with the specified service path.
-
batch
Deprecated.- Specified by:
batchin interfaceBatchService<MaterialDocumentServiceBatch>
-
getAllMaterialDocumentHeader
Deprecated.Description copied from interface:MaterialDocumentServiceFetch multipleMaterialDocumentHeaderentities.- Specified by:
getAllMaterialDocumentHeaderin interfaceMaterialDocumentService- Returns:
- A fluent helper to fetch multiple
MaterialDocumentHeaderentities. This fluent helper allows methods which modify the underlying query to be called before executing the query itself. To perform execution, call theexecutemethod on the fluent helper object.
-
getMaterialDocumentHeaderByKey
@Nonnull public MaterialDocumentHeaderByKeyFluentHelper getMaterialDocumentHeaderByKey(String materialDocumentYear, String materialDocument) Deprecated.Description copied from interface:MaterialDocumentServiceFetch a singleMaterialDocumentHeaderentity using key fields.- Specified by:
getMaterialDocumentHeaderByKeyin interfaceMaterialDocumentService- Parameters:
materialDocumentYear- Material Document YearConstraints: Not nullable, Maximum length: 4
materialDocument- Number of Material DocumentConstraints: Not nullable, Maximum length: 10
- Returns:
- A fluent helper to fetch a single
MaterialDocumentHeaderentity using key fields. This fluent helper allows methods which modify the underlying query to be called before executing the query itself. To perform execution, call theexecutemethod on the fluent helper object.
-
createMaterialDocumentHeader
@Nonnull public MaterialDocumentHeaderCreateFluentHelper createMaterialDocumentHeader(@Nonnull MaterialDocumentHeader materialDocumentHeader) Deprecated.Description copied from interface:MaterialDocumentServiceCreate a newMaterialDocumentHeaderentity and save it to the S/4HANA system.- Specified by:
createMaterialDocumentHeaderin interfaceMaterialDocumentService- Parameters:
materialDocumentHeader-MaterialDocumentHeaderentity object that will be created in the S/4HANA system.- Returns:
- A fluent helper to create a new
MaterialDocumentHeaderentity. To perform execution, call theexecutemethod on the fluent helper object.
-
getAllMaterialDocumentItem
Deprecated.Description copied from interface:MaterialDocumentServiceFetch multipleMaterialDocumentItementities.- Specified by:
getAllMaterialDocumentItemin interfaceMaterialDocumentService- Returns:
- A fluent helper to fetch multiple
MaterialDocumentItementities. This fluent helper allows methods which modify the underlying query to be called before executing the query itself. To perform execution, call theexecutemethod on the fluent helper object.
-
getMaterialDocumentItemByKey
@Nonnull public MaterialDocumentItemByKeyFluentHelper getMaterialDocumentItemByKey(String materialDocumentYear, String materialDocument, String materialDocumentItem) Deprecated.Description copied from interface:MaterialDocumentServiceFetch a singleMaterialDocumentItementity using key fields.- Specified by:
getMaterialDocumentItemByKeyin interfaceMaterialDocumentService- Parameters:
materialDocumentYear- Material Document YearConstraints: Not nullable, Maximum length: 4
materialDocument- Number of Material DocumentConstraints: Not nullable, Maximum length: 10
materialDocumentItem- Material Document ItemConstraints: Not nullable, Maximum length: 4
- Returns:
- A fluent helper to fetch a single
MaterialDocumentItementity using key fields. This fluent helper allows methods which modify the underlying query to be called before executing the query itself. To perform execution, call theexecutemethod on the fluent helper object.
-
getAllSerialNumberMaterialDocument
Deprecated.Description copied from interface:MaterialDocumentServiceFetch multipleSerialNumberMaterialDocumententities.- Specified by:
getAllSerialNumberMaterialDocumentin interfaceMaterialDocumentService- Returns:
- A fluent helper to fetch multiple
SerialNumberMaterialDocumententities. This fluent helper allows methods which modify the underlying query to be called before executing the query itself. To perform execution, call theexecutemethod on the fluent helper object.
-
getSerialNumberMaterialDocumentByKey
@Nonnull public SerialNumberMaterialDocumentByKeyFluentHelper getSerialNumberMaterialDocumentByKey(String material, String serialNumber, String materialDocument, String materialDocumentItem, String materialDocumentYear) Deprecated.Description copied from interface:MaterialDocumentServiceFetch a singleSerialNumberMaterialDocumententity using key fields.- Specified by:
getSerialNumberMaterialDocumentByKeyin interfaceMaterialDocumentService- Parameters:
material- Material NumberConstraints: Not nullable, Maximum length: 40
serialNumber- Serial NumberConstraints: Not nullable, Maximum length: 18
materialDocument- Number of Material DocumentConstraints: Not nullable, Maximum length: 10
materialDocumentItem- Material Document ItemConstraints: Not nullable, Maximum length: 4
materialDocumentYear- Material Document YearConstraints: Not nullable, Maximum length: 4
- Returns:
- A fluent helper to fetch a single
SerialNumberMaterialDocumententity using key fields. This fluent helper allows methods which modify the underlying query to be called before executing the query itself. To perform execution, call theexecutemethod on the fluent helper object.
-
cancel
@Nonnull public CancelFluentHelper cancel(@Nonnull String materialDocumentYear, @Nonnull String materialDocument, @Nullable LocalDateTime postingDate) Deprecated.Description copied from interface:MaterialDocumentServiceCreates a fluent helper for the Cancel OData function import.
- Specified by:
cancelin interfaceMaterialDocumentService- Parameters:
materialDocumentYear- Material Doc. YearConstraints: Not nullable, Maximum length: 4
Original parameter name from the Odata EDM: MaterialDocumentYear
materialDocument- Material DocumentConstraints: Not nullable, Maximum length: 10
Original parameter name from the Odata EDM: MaterialDocument
postingDate- Posting DateConstraints: Nullable, Precision: 0
Original parameter name from the Odata EDM: PostingDate
- Returns:
- A fluent helper object that will execute the Cancel OData function import with the provided
parameters. To perform execution, call the
executemethod on the fluent helper object.
-
cancelItem
@Nonnull public CancelItemFluentHelper cancelItem(@Nonnull String materialDocumentYear, @Nonnull String materialDocument, @Nonnull String materialDocumentItem, @Nullable LocalDateTime postingDate) Deprecated.Description copied from interface:MaterialDocumentServiceCreates a fluent helper for the CancelItem OData function import.
- Specified by:
cancelItemin interfaceMaterialDocumentService- Parameters:
materialDocumentYear- Material Doc. YearConstraints: Not nullable, Maximum length: 4
Original parameter name from the Odata EDM: MaterialDocumentYear
materialDocument- Material DocumentConstraints: Not nullable, Maximum length: 10
Original parameter name from the Odata EDM: MaterialDocument
materialDocumentItem- Material Doc.ItemConstraints: Not nullable, Maximum length: 4
Original parameter name from the Odata EDM: MaterialDocumentItem
postingDate- Posting DateConstraints: Nullable, Precision: 0
Original parameter name from the Odata EDM: PostingDate
- Returns:
- A fluent helper object that will execute the CancelItem OData function import with the provided
parameters. To perform execution, call the
executemethod on the fluent helper object.
-