Package de.aeb.xnsg.storage.bf.dto
Class StorageObjectDTO
- java.lang.Object
-
- de.aeb.xnsg.storage.bf.dto.AbstractStorageObjectDTO
-
- de.aeb.xnsg.storage.bf.dto.StorageObjectDTO
-
- All Implemented Interfaces:
Cloneable
public class StorageObjectDTO extends AbstractStorageObjectDTO
Represents the storage object to/from the storage system with allStorageKeyFieldDTO
and one to manyStorageDocumentDTO
objects.
-
-
Field Summary
Fields Modifier and Type Field Description String
businessArea
This is the name of the business area, to which the storage data belongs to (eg.String
companyName
This is the name of the global company of this customer.
The difference between global company name and client name is for business service provider which have to separate the data for their customers.StorageDocumentDTO[]
documents
A list ofStorageDocumentDTO
objects which represents the concrete data to store in the storage system.String
fulltextString
An optional text field which should be fulltext-indexed.
This depends on the concrete implementation of the used storage adapter.StorageKeyFieldDTO[]
keys
A list ofStorageKeyFieldDTO
which are defined/set by the business application.String
objectDate
The timestamp if this object.String
objectIdentifier
The identifier of this storage object.String
objectType
The object type describes the storage object from the business application point of view (eg.String
retentionTimestamp
The concrete timestamp to which this document must be at least stored in the storage system.StorageRevisionInfoDTO
revisionInfo
The id of the former StorageObject, if this should be a new revision.DataSetStructureDTO
structure
the object structure, if a serialized version of the object should be archived (only required, if the structure is unknown -> see StorageStoreDataResponseDTO->RESULT_STRUCTURE_UNKNOWN)Integer
structureMajorVersion
the major version of the object structure, if a serialized version of the object should be archivedInteger
structureMinorVersion
the major version of the object structure, if a serialized version of the object should be archivedString
systemId
The ID of the business application which want to store the data (eg.String
systemVersion
The version of the business application which want to store the data (eg.String
transactionId
This id is used for transactional processing of a storage object.
-
Constructor Summary
Constructors Constructor Description StorageObjectDTO()
Constructs a new object for a storage transaction.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addKey(String name, String value)
add the name value pair as key field to the key field array, does nothing if there is already a key with this namevoid
addKey(String name, String value, boolean overwrite)
add the name value pair as key field to the key field arrayObject
clone()
boolean
equals(Object obj)
StorageKeyFieldDTO
getKey(String key)
get the key with the name or null if it does not existint
hashCode()
void
removeKey(String key)
removes the key with the namevoid
setDocumentsArray(List<StorageDocumentDTO> documentList)
sets the documents to the array like they are sorted in the list-
Methods inherited from class de.aeb.xnsg.storage.bf.dto.AbstractStorageObjectDTO
arraysEquals
-
-
-
-
Field Detail
-
transactionId
public String transactionId
This id is used for transactional processing of a storage object. The storage interface must check the transaction ID and if it was used in former transactions, the actual transaction is aborted. The id must be unique within a client.
-
businessArea
public String businessArea
This is the name of the business area, to which the storage data belongs to (eg. Customs outbound).
-
companyName
public String companyName
This is the name of the global company of this customer.
The difference between global company name and client name is for business service provider which have to separate the data for their customers. In addition, there are use-cases where different departments of the same company must not mix the data.
-
objectType
public String objectType
The object type describes the storage object from the business application point of view (eg. ATLAS-Ausfuhr object).
-
structureMajorVersion
public Integer structureMajorVersion
the major version of the object structure, if a serialized version of the object should be archived
-
structureMinorVersion
public Integer structureMinorVersion
the major version of the object structure, if a serialized version of the object should be archived
-
structure
public DataSetStructureDTO structure
the object structure, if a serialized version of the object should be archived (only required, if the structure is unknown -> see StorageStoreDataResponseDTO->RESULT_STRUCTURE_UNKNOWN)
-
objectIdentifier
public String objectIdentifier
The identifier of this storage object. This value must be set by the business application and MUST be unique.
-
objectDate
public String objectDate
The timestamp if this object. This field is filled specific to the business use-cases (eg. for an ATLAS message this is the timestamp of EDIFCT file) The timestamp is formatted YYYY-MM-DDTHH:MM:SS in UTC time.
-
retentionTimestamp
public String retentionTimestamp
The concrete timestamp to which this document must be at least stored in the storage system. This value is very important for GDPDU compliant storage systems. The timestamp is formatted YYYY-MM-DDTHH:MM:SS in UTC time.
-
fulltextString
public String fulltextString
An optional text field which should be fulltext-indexed.
This depends on the concrete implementation of the used storage adapter.
-
systemId
public String systemId
The ID of the business application which want to store the data (eg. an XNSG-Engine). This ID should be unique so that the storage system can identify from which system the data was send.
-
systemVersion
public String systemVersion
The version of the business application which want to store the data (eg. an XNSG-Engine).
-
revisionInfo
public StorageRevisionInfoDTO revisionInfo
The id of the former StorageObject, if this should be a new revision. This DTO is null, if it is a new object and no revision should be created. This object is also filled in a call toIStorageBF.getData(de.aeb.xnsg.storage.bf.dto.request.StorageGetDataRequestDTO)
, if the returned object is a revision, otherwise this object is null.
-
keys
public StorageKeyFieldDTO[] keys
A list ofStorageKeyFieldDTO
which are defined/set by the business application.
-
documents
public StorageDocumentDTO[] documents
A list ofStorageDocumentDTO
objects which represents the concrete data to store in the storage system. AStorageObjectDTO
can contain one to manyStorageDocumentDTO
objects.
Be aware that the support of multipleStorageDocumentDTO
objects depends on the implementation and the used storage adapter.
-
-
Method Detail
-
hashCode
public int hashCode()
- Specified by:
hashCode
in classAbstractStorageObjectDTO
-
equals
public boolean equals(Object obj)
- Specified by:
equals
in classAbstractStorageObjectDTO
-
clone
public Object clone() throws CloneNotSupportedException
- Overrides:
clone
in classAbstractStorageObjectDTO
- Throws:
CloneNotSupportedException
-
setDocumentsArray
public void setDocumentsArray(List<StorageDocumentDTO> documentList)
sets the documents to the array like they are sorted in the list- Parameters:
documentListTmp
-
-
getKey
public StorageKeyFieldDTO getKey(String key)
get the key with the name or null if it does not exist
-
addKey
public void addKey(String name, String value)
add the name value pair as key field to the key field array, does nothing if there is already a key with this name
-
addKey
public void addKey(String name, String value, boolean overwrite)
add the name value pair as key field to the key field array- Parameters:
overwrite
- existing name
-
removeKey
public void removeKey(String key)
removes the key with the name
-
-