com.ibm.commerce.attachment.beans
Class AttachmentAssetDataBean
- java.lang.Object
-
- com.ibm.commerce.persistence.AbstractJpaEntityAccessBean
-
- com.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
-
- com.ibm.commerce.attachment.beans.AttachmentAssetDataBean
-
- All Implemented Interfaces:
- java.io.Serializable
public class AttachmentAssetDataBean extends com.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
This data bean represents an attachment asset of an attachment target.
This data bean is not intended to use for display purpose. Please use theAttachmentDataBean
when displaying the attachment.
Only the getter methods that returns String type are supported in this databean. The following getters are supported by this databean:- getAttachmentAssetId()
- getAttachmentTargetId()
- getStoreentId()
- getAttachmentAssetPath()
- getDirectoryPath()
- getImage1()
- getImage2()
- getMimeType()
- getMimeTypeEncoding()
- getLanguages()
- getContent()
- getComandContext
- getRequestProperties()
- setAttachmentAssetId(Long)
- setAttachmentTargetId(Long)
- setStoreentId(Integer)
- setAttachmentAssetPath(String)
- setDirectoryPath(String)
- setImage1(String)
- setImage2(String)
- setMimeType(String)
- setMimeTypeEncoding(String)
- setLanguages(Integer[])
- setContent(byte[])
- setCommandContext(CommandContext)
- setRequestProperties(TypeProperties
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field and Description static java.lang.String
CLASSNAME
Define the CLASSNAME.static java.lang.String
COPYRIGHT
The internal copyright field.
-
Constructor Summary
Constructors Constructor and Description AttachmentAssetDataBean()
Constructs an emptyAttachmentAssetDataBean
.AttachmentAssetDataBean(com.ibm.commerce.attachment.objects.AttachmentAssetAccessBean abAttachmentAsset, CommandContext context)
Constructs and populates anAttachmentAssetDataBean
from aAttachmentAssetAccessBean
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description AttachmentAssetLanguageDataBean[]
getAssetLanguages()
Gets the list ofAttachmentAssetLanguageDataBean
of the attachment asset.java.lang.String
getAttachmentAssetId()
Gets the attachment asset ID.java.lang.String
getAttachmentAssetPath()
Gets the path of the attachment asset.java.lang.String
getAttachmentTargetId()
Gets the attachment target ID.CommandContext
getCommandContext()
Gets the command context set within this bean.byte[]
getContent()
Gets the content of the attachment asset.java.lang.String
getDirectoryPath()
Gets the directory path of the attachment asset.java.lang.String
getImage1()
Gets the image 1 of the attachment asset.java.lang.String
getImage2()
Gets the image 2 of the attachment asset.java.lang.Integer[]
getLanguages()
Gets the list of languages supported by the attachment asset.java.lang.String
getMimeType()
Gets the mime type of the attachment asset.java.lang.String
getMimeTypeEncoding()
Gets the encoding of the mime type of the attachment asset.java.lang.String
getObjectPath()
Gets the path to attachment asset object based on the store ID in the attachment asset.TypedProperty
getRequestProperties()
Gets the request property set within this bean.java.lang.String
getStoreentId()
Gets the store entity ID.void
populate()
Fetches and populates information needed by the bean.void
reset()
Resets the databeanvoid
setAttachmentAssetId(java.lang.Long anAttachmentAssetId)
Sets the attachment asset ID.void
setAttachmentAssetPath(java.lang.String astrAttachmentAssetPath)
Sets the path of the attachment asset.void
setAttachmentTargetId(java.lang.Long anAttachmentTargetId)
Sets the attachment target ID.void
setCommandContext(CommandContext commandContext)
Sets the command context passed in at run time.void
setContent(byte[] abaContent)
Sets the attachment asset file content.void
setDirectoryPath(java.lang.String astrDirectoryPath)
Sets the directory path of the attachment asset.void
setImage1(java.lang.String astrImage1)
Sets the image 1 of the attachment asset.void
setImage2(java.lang.String astrImage2)
Sets the image 2 of the attachment asset.void
setLanguages(java.lang.Integer[] aarnLanguages)
Sets the list of languages supported by the attachment asset.void
setMimeType(java.lang.String astrMimeType)
Sets the mime type of the attachment assetvoid
setMimeTypeEncoding(java.lang.String astrMimeTypeEncoding)
Sets the encoding of the mime type of the attachment asset.void
setRequestProperties(TypedProperty param)
Sets the request property and populates the parameters that are needed by the bean.void
setStoreentId(java.lang.Integer anStoreentId)
Sets the store entity ID.-
Methods inherited from class com.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
findByAssetPath, findByAssetPathAndStoreentId, findByAttachmentTargetIdAndLanguageId, findByDirectoryPath, findByDirectoryPathAndStoreentId, findByStoreentId, findByStoreentIdAndMimeType, findByStoreentIdAndTargetId, findByStoreentIdAndTargetIdAndAssetPath, findByTargetId, getAttachmentAssetIdInEntityType, getAttachmentAssetLanguages, getAttachmentTargetIdInEntityType, getEntity, getStoreentIdInEntityType, getTimeCreated, getTimeCreatedInEntityType, getTimeUpdated, getTimeUpdatedInEntityType, instantiateEntity, setAttachmentTargetId, setInitKey_attachmentAssetId, setStoreentId, setTimeCreated, setTimeCreated, setTimeUpdated, setTimeUpdated
-
-
-
-
Field Detail
-
COPYRIGHT
public static final java.lang.String COPYRIGHT
The internal copyright field.- See Also:
- Constant Field Values
-
CLASSNAME
public static final java.lang.String CLASSNAME
Define the CLASSNAME.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
AttachmentAssetDataBean
public AttachmentAssetDataBean()
Constructs an emptyAttachmentAssetDataBean
.
-
AttachmentAssetDataBean
public AttachmentAssetDataBean(com.ibm.commerce.attachment.objects.AttachmentAssetAccessBean abAttachmentAsset, CommandContext context)
Constructs and populates anAttachmentAssetDataBean
from aAttachmentAssetAccessBean
. If error then the databean will be reset. All the variables become null.- Parameters:
abAttachmentAsset
- TheAttachmentAssetAccessBean
context
- The command context
-
-
Method Detail
-
getAttachmentAssetId
public java.lang.String getAttachmentAssetId()
Gets the attachment asset ID.- Overrides:
getAttachmentAssetId
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The attachment asset ID
-
getAttachmentTargetId
public java.lang.String getAttachmentTargetId()
Gets the attachment target ID.- Overrides:
getAttachmentTargetId
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The attachment target ID
-
getStoreentId
public java.lang.String getStoreentId()
Gets the store entity ID.- Overrides:
getStoreentId
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The store entity ID
-
getAttachmentAssetPath
public java.lang.String getAttachmentAssetPath()
Gets the path of the attachment asset.- Overrides:
getAttachmentAssetPath
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The attachment asset path
-
getObjectPath
public java.lang.String getObjectPath()
Gets the path to attachment asset object based on the store ID in the attachment asset.- Returns:
- The path to the attachment asset object
-
getDirectoryPath
public java.lang.String getDirectoryPath()
Gets the directory path of the attachment asset.- Overrides:
getDirectoryPath
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The attachment asset directory path
-
getImage1
public java.lang.String getImage1()
Gets the image 1 of the attachment asset.- Overrides:
getImage1
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The image 1
-
getImage2
public java.lang.String getImage2()
Gets the image 2 of the attachment asset.- Overrides:
getImage2
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The image 2
-
getMimeType
public java.lang.String getMimeType()
Gets the mime type of the attachment asset.- Overrides:
getMimeType
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The mime type
-
getMimeTypeEncoding
public java.lang.String getMimeTypeEncoding()
Gets the encoding of the mime type of the attachment asset.- Overrides:
getMimeTypeEncoding
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Returns:
- The mime type encoding of the attachment asset
-
getLanguages
public java.lang.Integer[] getLanguages()
Gets the list of languages supported by the attachment asset.- Returns:
- The list of supported languages
-
getContent
public byte[] getContent()
Gets the content of the attachment asset.- Returns:
- The attachment asset content
-
getCommandContext
public CommandContext getCommandContext()
Gets the command context set within this bean.- Returns:
- The command context as
CommandContext
object.
-
getRequestProperties
public TypedProperty getRequestProperties()
Gets the request property set within this bean.- Returns:
null
is always returned.
-
reset
public void reset()
Resets the databean
-
getAssetLanguages
public AttachmentAssetLanguageDataBean[] getAssetLanguages()
Gets the list ofAttachmentAssetLanguageDataBean
of the attachment asset.- Returns:
- The list of
AttachmentAssetLanguageDataBean
-
populate
public void populate()
Fetches and populates information needed by the bean.- Throws:
Any
- exception captured
-
setCommandContext
public void setCommandContext(CommandContext commandContext)
Sets the command context passed in at run time.- Parameters:
aCommandContext
- The command context asCommandContext
object.
-
setLanguages
public void setLanguages(java.lang.Integer[] aarnLanguages)
Sets the list of languages supported by the attachment asset.- Parameters:
aarnLanguages
- The list of languages supported by the attachment asset
-
setContent
public void setContent(byte[] abaContent)
Sets the attachment asset file content.- Parameters:
abaContent
- The content of the attachment asset
-
setRequestProperties
public void setRequestProperties(TypedProperty param)
Sets the request property and populates the parameters that are needed by the bean.- Parameters:
param
- The request property asTypedProperty
object.
-
setAttachmentAssetId
public void setAttachmentAssetId(java.lang.Long anAttachmentAssetId)
Sets the attachment asset ID.- Parameters:
anAttachmentAssetId
- The attachment asset ID
-
setStoreentId
public void setStoreentId(java.lang.Integer anStoreentId)
Sets the store entity ID.- Overrides:
setStoreentId
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
anStoreentId
- The store entity ID
-
setAttachmentTargetId
public void setAttachmentTargetId(java.lang.Long anAttachmentTargetId)
Sets the attachment target ID.- Overrides:
setAttachmentTargetId
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
anAttachmentTargetId
- The attachment target ID
-
setAttachmentAssetPath
public void setAttachmentAssetPath(java.lang.String astrAttachmentAssetPath)
Sets the path of the attachment asset.- Overrides:
setAttachmentAssetPath
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
astrAttachmentAssetPath
- The attachment asset path
-
setDirectoryPath
public void setDirectoryPath(java.lang.String astrDirectoryPath)
Sets the directory path of the attachment asset.- Overrides:
setDirectoryPath
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
astrDirectoryPath
- The attachment asset directory path
-
setImage1
public void setImage1(java.lang.String astrImage1)
Sets the image 1 of the attachment asset.- Overrides:
setImage1
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
astrImage1
- The attachment asset image 1
-
setImage2
public void setImage2(java.lang.String astrImage2)
Sets the image 2 of the attachment asset.- Overrides:
setImage2
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
astrImage2
- The attachment asset image 2
-
setMimeType
public void setMimeType(java.lang.String astrMimeType)
Sets the mime type of the attachment asset- Overrides:
setMimeType
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
astrMimeType
- The mime type of the attachment asset
-
setMimeTypeEncoding
public void setMimeTypeEncoding(java.lang.String astrMimeTypeEncoding)
Sets the encoding of the mime type of the attachment asset.- Overrides:
setMimeTypeEncoding
in classcom.ibm.commerce.attachment.objects.AttachmentAssetAccessBean
- Parameters:
astrMimeTypeEncoding
- The mime type encoding of the attachment asset
-
-