Package org.bedework.calfacade
Class BwResourceContent
java.lang.Object
- All Implemented Interfaces:
Serializable,Comparable<BwResourceContent>,org.bedework.util.logging.Logged
Represent the content for a resource stored within the system, e.g an attachment or an
image. The actual content is stored in a BwResourceContent object to allow us
to put off retrieval of content - or maybe even store outside of the db.
- Author:
- Mike Douglass douglm - rpi.edu
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bedework.calfacade.base.DumpEntity
DumpEntity.DumpType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()Make visibleintcompareTo(BwResourceContent that) voidcopyTo(BwResourceContent val) Copy this objects values into the parameterbyte[]Get the byte array valueGet the object's collection pathgetHref()getName()Get the namegetValue()Get the valueinthashCode()voidsetByteValue(byte[] val) Set the byte array valuevoidsetColPath(String val) Set the object's collection pathvoidSet the href - ignoredvoidSet the namevoidSet the valuetoString()Methods inherited from class org.bedework.calfacade.base.BwDbentity
addDeletedEntity, afterDeletion, beforeDeletion, beforeSave, beforeUpdate, getByteSize, getDeletedEntities, getSeq, length, setByteSize, setSeqMethods inherited from class org.bedework.calfacade.base.BwUnversionedDbentity
equals, getId, markUnsaved, setId, toStringSegment, unsavedMethods inherited from class org.bedework.calfacade.base.DumpEntity
dump, dump, getLogger, hasDumpValueMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.bedework.util.logging.Logged
audit, debug, debug, debug, enableAuditLogger, enableErrorLogger, enableMetricsLogger, error, error, error, getLogLevel, info, isAuditLoggerEnabled, isErrorLoggerEnabled, isMetricsDebugEnabled, isMetricsLoggerEnabled, metrics, setLoggerClass, setLoggerClass, trace, trace, trace, warn
-
Constructor Details
-
BwResourceContent
public BwResourceContent()Constructor
-
-
Method Details
-
setColPath
Set the object's collection path- Parameters:
val- String path
-
getColPath
Get the object's collection path- Returns:
- String path
-
setName
Set the name- Parameters:
val- String name
-
getName
Get the name- Returns:
- String name
-
setValue
Set the value- Parameters:
val- byte[]
-
getValue
Get the value- Returns:
- Blob
-
setHref
Set the href - ignored- Overrides:
setHrefin classBwUnversionedDbentity<BwResourceContent>- Parameters:
val- String href
-
getHref
- Overrides:
getHrefin classBwUnversionedDbentity<BwResourceContent>- Returns:
- non null unique href for the entity
-
getBinaryStream
- Throws:
CalFacadeException
-
setByteValue
public void setByteValue(byte[] val) Set the byte array value- Parameters:
val- byte array value
-
getByteValue
public byte[] getByteValue()Get the byte array value- Returns:
- byte array or null
-
getEncodedContent
- Returns:
- base64 encoded value
-
getStringContent
- Returns:
- String value
-
copyTo
Copy this objects values into the parameter- Parameters:
val- resource content
-
hashCode
public int hashCode()- Overrides:
hashCodein classBwUnversionedDbentity<BwResourceContent>
-
compareTo
- Specified by:
compareToin interfaceComparable<BwResourceContent>- Overrides:
compareToin classBwUnversionedDbentity<BwResourceContent>
-
toString
-
clone
Description copied from class:BwUnversionedDbentityMake visible- Overrides:
clonein classBwUnversionedDbentity<BwResourceContent>- Returns:
- Object of class T
-