Package de.xima.fc.entities
Class Attachment
- java.lang.Object
-
- de.xima.cmn.dao.model.AEntity<Long>
-
- de.xima.fc.entities.AbstractEntity
-
- de.xima.fc.entities.AbstractLockableEntity
-
- de.xima.fc.entities.ALockableEntity
-
- de.xima.fc.entities.Attachment
-
- All Implemented Interfaces:
de.xima.cmn.dao.interfaces.IEntity<Long>,de.xima.cmn.dao.interfaces.ILockableEntity<Long>,IFileProviding<AttachmentDatei,AttachmentDateiData>,ILockingVersionProviding,IMandantDependent,ITransferable,ITransferableEntity,ITransferableLockableEntity,IUncacheableDatei,IUncacheableFile,IUUIDEntity,IVorgangDependent,Serializable,Comparable<de.xima.cmn.dao.interfaces.IEntity<Long>>
@Entity public class Attachment extends ALockableEntity implements IFileProviding<AttachmentDatei,AttachmentDateiData>, IVorgangDependent, IUncacheableFile, IUUIDEntity, IMandantDependent
Die KlasseAttachmentbeinhaltet Meta-Informationen zu einem im System verfügbaren Anhang. Dieser Anhang kann zum einen eine Datei sein, die in einem Formular hochgeladen wurde, zum andern kann es sich um eine Datei handeln, die von einem 'Postfachbearbeiter' einemVorgangangefügt wurde.- Author:
- XIMA MEDIA GmbH
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringATTR_ELEMENT_NAMEstatic StringATTR_FORMEINGANGDeprecated.static StringATTR_LOESCHBARstatic StringATTR_MANDANTDeprecated.will be removed, useAClientDependentEntity.getMandant()static StringATTR_OUTPUT_ALIASstatic StringATTR_SOURCEstatic StringATTR_VORGANGstatic StringCOL_ACCESSIBLE_TO_ENDUSERstatic StringCOL_FORM_RECORD_META_IDstatic StringCOL_UUID-
Fields inherited from class de.xima.fc.entities.AbstractLockableEntity
COL_LOCKINGVERSION, lockingVersion
-
Fields inherited from class de.xima.fc.entities.AbstractEntity
COL_ID, id
-
Fields inherited from interface de.xima.fc.entities.interfaces.IFileProviding
ATTR_DATEI, ATTR_FILE
-
Fields inherited from interface de.xima.fc.entities.interfaces.IMandantDependent
COL_CLIENT_ID
-
Fields inherited from interface de.xima.fc.entities.interfaces.ITransferableEntity
IMPORT_ID, INVALID_ID
-
Fields inherited from interface de.xima.fc.entities.interfaces.IUUIDEntity
ATTR_UUID, INVALID_UUID, INVALID_UUID_OBJECT, NULL_SAFE_UUID_TYPE, NULLABLE_UUID_TYPE, TYPE_NAME_UUID
-
-
Constructor Summary
Constructors Constructor Description Attachment()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description AttachmentcloneBasics()StringgetBenutzer()Diese Methode dient dazu, eine Zeichenkette zu erhalten, die Schlussfolgerungen auf den Ersteller dieses Attachments zulässtStringgetDateiName()Diese Methode dient dazu, den Namen desAttachmentzu erhaltenStringgetElementName()Diese Methode dient dazu, den Formularelementnamen zu erhalten, in welchem dasAttachmentangebenen wurdeAttachmentDateigetFileEntity()FormEinganggetFormEingang()Optional.LonggetId()MandantgetMandant()Deprecated.will be removed, usegetVorgang()andAClientDependentEntity.getMandant()StringgetOutputAlias()Deprecated.will be removed.EAttachmentSourcegetSource()DategetUploadDatum()Diese Methode dient dazu, das Datum zu setzen, an welchem dasAttachmenthochgeladen wurdeStringgetUuid()StringgetUUID()Gets the UUID (universal unique identifier) that uniquely identifies this type of entity.UUIDgetUUIDObject()Gets the UUID (universal unique identifier) that uniquely identifies this type of entity.VorganggetVorgang()Diese Methode dient dazu, denVorgangzu ermitteln, zu dem dasAttachmenthinzugefügt wurdebooleanisAccessibleToEndUser()booleanisLoeschbar()Attachments sind dann löschbar, wenn der zugehörige Vorgang löschbar ist (Vorgänge sind löschbar, wenn der Status, in dem sie sich befinden, das Löschen von Vorgängen erlaubt).voidsetAccessibleToEndUser(boolean accessibleToEndUser)voidsetElementName(String elementName)Diese Methode dient dazu, den Formularelementnamen zu setzenvoidsetFileEntity(AttachmentDatei fileEntity)voidsetFormEingang(FormEingang formRecordData)Optional.voidsetId(Long id)!!!WARNING: Currently values biggerInteger.MAX_VALUEor lower thenInteger.MIN_VALUEwill be altered to null!!!voidsetMandant(Mandant mandant)Deprecated.will be removed, usegetVorgang()andAClientDependentEntity.setMandant(Mandant)voidsetOutputAlias(String outputAlias)Deprecated.will be removed.voidsetSource(EAttachmentSource source)voidsetUuid(String uuid)voidsetUUID(String uuid)Sets the UUID (universal unique identifier) that uniquely identifies this type of entity.voidsetUUIDObject(UUID uuid)voidsetVorgang(Vorgang vorgang)Diese Methode dient dazu, den Vorgang zu setzten, zu dem dasAttachmentzugehörig ist (Bedingung: nicht null).-
Methods inherited from class de.xima.fc.entities.AbstractLockableEntity
entityHasChanged, getLockingVersion, setLockingVersion, toString
-
Methods inherited from class de.xima.fc.entities.AbstractEntity
asIntValue, isPersisted, setId
-
Methods inherited from class de.xima.cmn.dao.model.AEntity
compareTo, equals, getDBTableName, hashCode
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface de.xima.fc.entities.interfaces.IFileProviding
getDatei, setDatei
-
-
-
-
Field Detail
-
ATTR_VORGANG
public static final String ATTR_VORGANG
- See Also:
- Constant Field Values
-
ATTR_ELEMENT_NAME
public static final String ATTR_ELEMENT_NAME
- See Also:
- Constant Field Values
-
ATTR_OUTPUT_ALIAS
public static final String ATTR_OUTPUT_ALIAS
- See Also:
- Constant Field Values
-
ATTR_SOURCE
public static final String ATTR_SOURCE
- See Also:
- Constant Field Values
-
ATTR_LOESCHBAR
public static final String ATTR_LOESCHBAR
- See Also:
- Constant Field Values
-
COL_UUID
public static final String COL_UUID
- See Also:
- Constant Field Values
-
COL_ACCESSIBLE_TO_ENDUSER
public static final String COL_ACCESSIBLE_TO_ENDUSER
- See Also:
- Constant Field Values
-
COL_FORM_RECORD_META_ID
public static final String COL_FORM_RECORD_META_ID
- See Also:
- Constant Field Values
-
ATTR_MANDANT
@Deprecated public static final String ATTR_MANDANT
Deprecated.will be removed, useAClientDependentEntity.getMandant()- See Also:
- Constant Field Values
-
ATTR_FORMEINGANG
@Deprecated public static final String ATTR_FORMEINGANG
Deprecated.- See Also:
- Constant Field Values
-
-
Method Detail
-
setId
public void setId(Long id)
Description copied from class:AbstractEntity!!!WARNING: Currently values biggerInteger.MAX_VALUEor lower thenInteger.MIN_VALUEwill be altered to null!!!- Specified by:
setIdin interfacede.xima.cmn.dao.interfaces.IEntity<Long>- Overrides:
setIdin classAbstractEntity- Parameters:
id-Longthe database-id to set
-
getUUID
public String getUUID()
Description copied from interface:IUUIDEntityGets the UUID (universal unique identifier) that uniquely identifies this type of entity. Whether the UUID must be globally unique or only with within a context depends on the type of entity. Common contexts are for exampleclient scopesorproject scope.- Specified by:
getUUIDin interfaceIUUIDEntity- Returns:
- The UUID of the entity.
-
setUUID
public void setUUID(String uuid)
Description copied from interface:IUUIDEntitySets the UUID (universal unique identifier) that uniquely identifies this type of entity. Whether the UUID must be globally unique or only with within a context depends on the type of entity. Common contexts are for exampleclient scopesorproject scope.- Specified by:
setUUIDin interfaceIUUIDEntity- Parameters:
uuid- The UUID of the entity.
-
getUUIDObject
public UUID getUUIDObject()
Description copied from interface:IUUIDEntityGets the UUID (universal unique identifier) that uniquely identifies this type of entity. Whether the UUID must be globally unique or only with within a context depends on the type of entity. Common contexts are for exampleclient scopesorproject scope.- Specified by:
getUUIDObjectin interfaceIUUIDEntity- Returns:
- The UUID of the entity.
-
setUUIDObject
public void setUUIDObject(UUID uuid)
-
getVorgang
public Vorgang getVorgang()
Diese Methode dient dazu, denVorgangzu ermitteln, zu dem dasAttachmenthinzugefügt wurde- Specified by:
getVorgangin interfaceIVorgangDependent- Returns:
Vorgangs-Instanz
-
setVorgang
public void setVorgang(Vorgang vorgang)
Diese Methode dient dazu, den Vorgang zu setzten, zu dem dasAttachmentzugehörig ist (Bedingung: nicht null).- Parameters:
vorgang- -Vorgang-Objekt
-
cloneBasics
public Attachment cloneBasics()
- Returns:
- A copy of this entity with all fields copied that do not reference other entities. The
getUUIDObject()is not copied.
-
getBenutzer
public String getBenutzer()
Diese Methode dient dazu, eine Zeichenkette zu erhalten, die Schlussfolgerungen auf den Ersteller dieses Attachments zulässt- Returns:
- Nutzerkennung oder Nutzername
-
getUploadDatum
public Date getUploadDatum()
Diese Methode dient dazu, das Datum zu setzen, an welchem dasAttachmenthochgeladen wurde- Returns:
Date-Objekt odernull
-
getDateiName
public String getDateiName()
Diese Methode dient dazu, den Namen desAttachmentzu erhalten- Returns:
- Zeichenkette mit dem Dateinamen
-
getElementName
public String getElementName()
Diese Methode dient dazu, den Formularelementnamen zu erhalten, in welchem dasAttachmentangebenen wurde- Returns:
- Zeichenkette mit dem Elementnamen oder
null
-
setElementName
public void setElementName(String elementName)
Diese Methode dient dazu, den Formularelementnamen zu setzen- Parameters:
elementName- - Zeichenkette für den Elementnamen odernull
-
isLoeschbar
public boolean isLoeschbar()
Attachments sind dann löschbar, wenn der zugehörige Vorgang löschbar ist (Vorgänge sind löschbar, wenn der Status, in dem sie sich befinden, das Löschen von Vorgängen erlaubt).- Returns:
true, wenn dieses Attachment löschbar ist, ansonstenfalse.- See Also:
Vorgang.isLoeschbar()
-
getFileEntity
public AttachmentDatei getFileEntity()
- Specified by:
getFileEntityin interfaceIFileProviding<AttachmentDatei,AttachmentDateiData>
-
setFileEntity
public void setFileEntity(AttachmentDatei fileEntity)
- Specified by:
setFileEntityin interfaceIFileProviding<AttachmentDatei,AttachmentDateiData>
-
getFormEingang
public FormEingang getFormEingang()
Optional. The form record data from the submission that created this attachment. Available only if the attachment was created by an upload from an HTML input file element. When the attachment got created in other manners (such as by a workflow action or manually in the inbox), this will be null.Note: This feature was disabled in the past and got enabled again starting with version 8.2.0. For
form recordscreated by older versions of formcycle, this field will be null even for attachments from form uploads.- Returns:
- The form record data from the form submission where this attachment was created.
-
setFormEingang
public void setFormEingang(FormEingang formRecordData)
Optional. The form record data from the submission that created this attachment. Available only if the attachment was created by an upload from an HTML input file element. When the attachment got created in other manners (such as by a workflow action or manually in the inbox), this will be null.Note: This feature was disabled in the past and got enabled again starting with version 8.2.0. For
form recordscreated by older versions of formcycle, this field will be null even for attachments from form uploads.- Parameters:
formRecordData- The form record data from the form submission where this attachment was created.
-
getSource
public EAttachmentSource getSource()
-
setSource
public void setSource(EAttachmentSource source)
-
isAccessibleToEndUser
public boolean isAccessibleToEndUser()
-
setAccessibleToEndUser
public void setAccessibleToEndUser(boolean accessibleToEndUser)
-
getUuid
public String getUuid()
- Returns:
- uuid
-
setUuid
public void setUuid(String uuid)
- Parameters:
uuid- the uuid
-
getMandant
@Deprecated public Mandant getMandant()
Deprecated.will be removed, usegetVorgang()andAClientDependentEntity.getMandant()- Specified by:
getMandantin interfaceIMandantDependent- Returns:
- returns the client or null if not set
-
setMandant
@Deprecated public void setMandant(Mandant mandant)
Deprecated.will be removed, usegetVorgang()andAClientDependentEntity.setMandant(Mandant)- Specified by:
setMandantin interfaceIMandantDependent
-
getOutputAlias
@Deprecated public String getOutputAlias()
Deprecated.will be removed. Currently returns the file name- Returns:
- the output alias
-
setOutputAlias
@Deprecated public void setOutputAlias(String outputAlias)
Deprecated.will be removed. Currently an NO-OP method- Parameters:
outputAlias- the output alias to set
-
-