Class LibraryEntry
java.lang.Object
org.deltava.beans.fleet.LibraryEntry
- All Implemented Interfaces:
Serializable,Cloneable,Comparable<LibraryEntry>,Auditable,ViewEntry,Cacheable
- Direct Known Subclasses:
FileEntry,FleetEntry,Newsletter
public abstract class LibraryEntry
extends Object
implements Comparable<LibraryEntry>, Cacheable, ViewEntry, Auditable
An abstract bean to store information about Library entries.
- Since:
- 1.0
- Version:
- 10.4
- Author:
- Luke
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal ObjectcacheKey()Returns the cache key for this object.intfile()Returns the underlying filesystem entry.Returns the object ID for this auditable object.Returns a description of this resource.intReturns the number of times this resource has been downloaded.Returns the filename of the resource, without paths.Gets the full pathname of the resource on the local filesystem.final StringgetName()Returns the name of the resource.getOwner()Returns the owning Virtual Airline.Returns the CSS class for this object if rendered in a view table.Returns this resource's security level.longgetSize()Returns the size of the resource.inthashCode()voidsetDescription(String desc) Updates the description of this resource.voidsetDownloadCount(int count) Updates the number of times this resource has been downloaded.voidUpdates the name of this resource.voidUpdates the owning Virtual Airline.voidsetSecurity(Security level) Updates this resource's security level.voidsetSize(long size) Updates the size of this resource.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.deltava.beans.Auditable
getAuditType, isCrossApp
-
Constructor Details
-
LibraryEntry
-
-
Method Details
-
getName
-
getFullName
Gets the full pathname of the resource on the local filesystem.- Returns:
- the full path to the resource
- See Also:
-
getFileName
Returns the filename of the resource, without paths.- Returns:
- the filename
- See Also:
-
getDescription
Returns a description of this resource.- Returns:
- the resource's description
- See Also:
-
getOwner
Returns the owning Virtual Airline.- Returns:
- an AirlineInformation bean
- See Also:
-
getDownloadCount
public int getDownloadCount()Returns the number of times this resource has been downloaded.- Returns:
- the number of downloads
- See Also:
-
getSecurity
Returns this resource's security level.- Returns:
- the security level for this entry
- See Also:
-
getSize
public long getSize()Returns the size of the resource.- Returns:
- the size of the resource in bytes, or 0 if it does not exist on the filesystem
- See Also:
-
setDownloadCount
public void setDownloadCount(int count) Updates the number of times this resource has been downloaded.- Parameters:
count- the download count
-
setDescription
Updates the description of this resource.- Parameters:
desc- the description- Throws:
NullPointerException- if desc is null- See Also:
-
setName
Updates the name of this resource.- Parameters:
name- the name- Throws:
NullPointerException- if name is null- See Also:
-
setSize
public void setSize(long size) Updates the size of this resource.- Parameters:
size- the size of the file in bytes- See Also:
-
setSecurity
Updates this resource's security level.- Parameters:
level- the security level code- See Also:
-
setOwner
Updates the owning Virtual Airline.- Parameters:
ai- an AirlineInfromation bean- See Also:
-
file
-
getAuditID
Description copied from interface:AuditableReturns the object ID for this auditable object.- Specified by:
getAuditIDin interfaceAuditable- Returns:
- the ID
-
compareTo
- Specified by:
compareToin interfaceComparable<LibraryEntry>
-
hashCode
-
getRowClassName
Description copied from interface:ViewEntryReturns the CSS class for this object if rendered in a view table.- Specified by:
getRowClassNamein interfaceViewEntry- Returns:
- the CSS class name, or NULL if none
-
cacheKey
-
toString
-