@Named(value="com.sap.cloud.sdk.s4hana.datamodel.odata.services.DefaultAttachmentService") public class DefaultAttachmentService extends Object implements AttachmentService
This service enables you to manage Document Management (DMS), and Generic Object Services (GOS) based attachments, such as creating, reading, renaming, and deleting attachments. You can also read an existing document info record (DIR), and add attachments to it..
Reference: SAP API Business Hub
DEFAULT_SERVICE_PATH
Constructor and Description |
---|
DefaultAttachmentService()
Creates a service using
AttachmentService.DEFAULT_SERVICE_PATH to send the requests. |
Modifier and Type | Method and Description |
---|---|
DefaultAttachmentServiceBatch |
batch()
Instantiate a new FluentHelper instance for a single OData batch request.
|
AttachmentContentCreateFluentHelper |
createAttachmentContent(AttachmentContent attachmentContent)
Create a new
AttachmentContent entity and save it to the S/4HANA system. |
DocumentInfoRecordAttchCreateFluentHelper |
createDocumentInfoRecordAttch(DocumentInfoRecordAttch documentInfoRecordAttch)
Create a new
DocumentInfoRecordAttch entity and save it to the S/4HANA system. |
CreateUrlAsAttachmentFluentHelper |
createUrlAsAttachment(String semanticObject,
String linkedSAPObjectKey,
String businessObjectTypeName,
String url,
String urlDescription,
String mIMEType)
Create URL as attachment
|
AttachmentContentDeleteFluentHelper |
deleteAttachmentContent(AttachmentContent attachmentContent)
Deletes an existing
AttachmentContent entity in the S/4HANA system. |
DocumentInfoRecordAttchFluentHelper |
getAllDocumentInfoRecordAttch()
Fetch multiple
DocumentInfoRecordAttch entities. |
GetAllOriginalsFluentHelper |
getAllOriginals(String linkedSAPObjectKey,
String businessObjectTypeName,
String semanticObject)
Returns All Originals Related to a Parent Object
|
GetAttachmentCountFluentHelper |
getAttachmentCount(String businessObjectTypeName,
String linkedSAPObjectKey,
String semanticObject)
Returns the Count of Attachments
|
DocumentInfoRecordAttchByKeyFluentHelper |
getDocumentInfoRecordAttchByKey(String documentInfoRecordDocType,
String documentInfoRecordDocNumber,
String documentInfoRecordDocVersion,
String documentInfoRecordDocPart)
Fetch a single
DocumentInfoRecordAttch entity using key fields. |
RenameAttachmentFluentHelper |
renameAttachment(String documentInfoRecordDocType,
String documentInfoRecordDocVersion,
String logicalDocument,
String archiveDocumentID,
String businessObjectTypeName,
String linkedSAPObjectKey,
String semanticObject,
String fileName,
String documentInfoRecordDocNumber,
String documentInfoRecordDocPart)
Rename Attachment
|
DefaultAttachmentService |
withServicePath(String servicePath)
Overrides the default service path and returns a new service instance with the specified service path.
|
public DefaultAttachmentService()
AttachmentService.DEFAULT_SERVICE_PATH
to send the requests.@Nonnull public DefaultAttachmentService withServicePath(@Nonnull String servicePath)
AttachmentService
withServicePath
in interface AttachmentService
servicePath
- Service path that will override the default.@Nonnull public DefaultAttachmentServiceBatch batch()
batch
in interface BatchService<AttachmentServiceBatch>
@Nonnull public AttachmentContentCreateFluentHelper createAttachmentContent(@Nonnull AttachmentContent attachmentContent)
AttachmentService
AttachmentContent
entity and save it to the S/4HANA system.createAttachmentContent
in interface AttachmentService
attachmentContent
- AttachmentContent
entity object that will be created in the S/4HANA system.AttachmentContent
entity. To perform execution, call the
execute
method on the fluent helper object.@Nonnull public AttachmentContentDeleteFluentHelper deleteAttachmentContent(@Nonnull AttachmentContent attachmentContent)
AttachmentService
AttachmentContent
entity in the S/4HANA system.deleteAttachmentContent
in interface AttachmentService
attachmentContent
- AttachmentContent
entity object that will be deleted in the S/4HANA system.AttachmentContent
entity. To perform execution, call the
execute
method on the fluent helper object.@Nonnull public DocumentInfoRecordAttchFluentHelper getAllDocumentInfoRecordAttch()
AttachmentService
DocumentInfoRecordAttch
entities.getAllDocumentInfoRecordAttch
in interface AttachmentService
DocumentInfoRecordAttch
entities. This fluent helper allows methods which modify the underlying query to
be called before executing the query itself. To perform execution, call the
execute
method on the fluent helper object.@Nonnull public DocumentInfoRecordAttchByKeyFluentHelper getDocumentInfoRecordAttchByKey(String documentInfoRecordDocType, String documentInfoRecordDocNumber, String documentInfoRecordDocVersion, String documentInfoRecordDocPart)
AttachmentService
DocumentInfoRecordAttch
entity using key fields.getDocumentInfoRecordAttchByKey
in interface AttachmentService
documentInfoRecordDocType
- Part of the document key, which categorizes documents according to their distinguishing features and
the organizational procedures which result from them.
Constraints: Not nullable, Maximum length: 3
documentInfoRecordDocNumber
- This number is the main part of the document key, which is used to identify the document.
Constraints: Not nullable, Maximum length: 25
documentInfoRecordDocVersion
- Number which identifies the version of a document.
Constraints: Not nullable, Maximum length: 2
documentInfoRecordDocPart
- Section of a document which is maintained as an independent document.
Constraints: Not nullable, Maximum length: 3
DocumentInfoRecordAttch
entity 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 the
execute
method on the fluent helper object.@Nonnull public DocumentInfoRecordAttchCreateFluentHelper createDocumentInfoRecordAttch(@Nonnull DocumentInfoRecordAttch documentInfoRecordAttch)
AttachmentService
DocumentInfoRecordAttch
entity and save it to the S/4HANA system.createDocumentInfoRecordAttch
in interface AttachmentService
documentInfoRecordAttch
- DocumentInfoRecordAttch
entity object that will be created in the S/4HANA system.DocumentInfoRecordAttch
entity. To perform execution, call the
execute
method on the fluent helper object.@Nonnull public GetAllOriginalsFluentHelper getAllOriginals(String linkedSAPObjectKey, String businessObjectTypeName, String semanticObject)
AttachmentService
Creates a fluent helper for the GetAllOriginals OData function import.
getAllOriginals
in interface AttachmentService
linkedSAPObjectKey
- LinkedSAPObjectKey
Constraints: Not nullable, Maximum length: 90
Original parameter name from the Odata EDM: LinkedSAPObjectKey
businessObjectTypeName
- BusinessObjectTypeName
Constraints: Not nullable, Maximum length: 40
Original parameter name from the Odata EDM: BusinessObjectTypeName
semanticObject
- SemanticObject
Constraints: Nullable, Maximum length: 40
Original parameter name from the Odata EDM: SemanticObject
execute
method on the fluent helper object.@Nonnull public GetAttachmentCountFluentHelper getAttachmentCount(String businessObjectTypeName, String linkedSAPObjectKey, String semanticObject)
AttachmentService
Creates a fluent helper for the GetAttachmentCount OData function import.
getAttachmentCount
in interface AttachmentService
businessObjectTypeName
- BusinessObjectTypeName
Constraints: Not nullable, Maximum length: 40
Original parameter name from the Odata EDM: BusinessObjectTypeName
linkedSAPObjectKey
- LinkedSAPObjectKey
Constraints: Not nullable, Maximum length: 90
Original parameter name from the Odata EDM: LinkedSAPObjectKey
semanticObject
- SemanticObject
Constraints: Nullable, Maximum length: 40
Original parameter name from the Odata EDM: SemanticObject
execute
method on the fluent helper object.@Nonnull public RenameAttachmentFluentHelper renameAttachment(String documentInfoRecordDocType, String documentInfoRecordDocVersion, String logicalDocument, String archiveDocumentID, String businessObjectTypeName, String linkedSAPObjectKey, String semanticObject, String fileName, String documentInfoRecordDocNumber, String documentInfoRecordDocPart)
AttachmentService
Creates a fluent helper for the RenameAttachment OData function import.
renameAttachment
in interface AttachmentService
documentInfoRecordDocType
- DocumentInfoRecordDocType
Constraints: Nullable, Maximum length: 3
Original parameter name from the Odata EDM: DocumentInfoRecordDocType
documentInfoRecordDocVersion
- DocumentInfoRecordDocVersion
Constraints: Nullable, Maximum length: 2
Original parameter name from the Odata EDM: DocumentInfoRecordDocVersion
logicalDocument
- LogicalDocument
Constraints: Not nullable, Maximum length: 32
Original parameter name from the Odata EDM: LogicalDocument
archiveDocumentID
- ArchiveDocumentID
Constraints: Not nullable, Maximum length: 40
Original parameter name from the Odata EDM: ArchiveDocumentID
businessObjectTypeName
- BusinessObjectTypeName
Constraints: Not nullable, Maximum length: 40
Original parameter name from the Odata EDM: BusinessObjectTypeName
linkedSAPObjectKey
- LinkedSAPObjectKey
Constraints: Not nullable, Maximum length: 90
Original parameter name from the Odata EDM: LinkedSAPObjectKey
semanticObject
- SemanticObject
Constraints: Nullable, Maximum length: 40
Original parameter name from the Odata EDM: SemanticObject
fileName
- FileName
Constraints: Not nullable, Maximum length: 255
Original parameter name from the Odata EDM: FileName
documentInfoRecordDocNumber
- DocumentInfoRecordDocNumber
Constraints: Nullable, Maximum length: 25
Original parameter name from the Odata EDM: DocumentInfoRecordDocNumber
documentInfoRecordDocPart
- DocumentInfoRecordDocPart
Constraints: Nullable, Maximum length: 3
Original parameter name from the Odata EDM: DocumentInfoRecordDocPart
execute
method on the fluent helper object.@Nonnull public CreateUrlAsAttachmentFluentHelper createUrlAsAttachment(String semanticObject, String linkedSAPObjectKey, String businessObjectTypeName, String url, String urlDescription, String mIMEType)
AttachmentService
Creates a fluent helper for the CreateUrlAsAttachment OData function import.
createUrlAsAttachment
in interface AttachmentService
semanticObject
- SemanticObject
Constraints: Not nullable, Maximum length: 40
Original parameter name from the Odata EDM: SemanticObject
linkedSAPObjectKey
- LinkedSAPObjectKey
Constraints: Not nullable, Maximum length: 90
Original parameter name from the Odata EDM: LinkedSAPObjectKey
businessObjectTypeName
- BusinessObjectTypeName
Constraints: Not nullable, Maximum length: 40
Original parameter name from the Odata EDM: BusinessObjectTypeName
url
- Url
Constraints: Not nullable, Maximum length: 255
Original parameter name from the Odata EDM: Url
urlDescription
- UrlDescription
Constraints: Not nullable, Maximum length: 255
Original parameter name from the Odata EDM: UrlDescription
mIMEType
- MIMEType
Constraints: Not nullable, Maximum length: 40
Original parameter name from the Odata EDM: MIMEType
execute
method on the fluent helper object.Copyright © 2020 SAP SE. All rights reserved.