RichFaces Photoalbum 4.3.5.Final

org.richfaces.photoalbum.model
Class Image

java.lang.Object
  extended by org.richfaces.photoalbum.model.Image
All Implemented Interfaces:
Serializable

@Entity
public class Image
extends Object
implements Serializable

See Also:
Serialized Form

Constructor Summary
Image()
           
 
Method Summary
 void addComment(Comment comment)
          Add comment to this image.
 void addMetaTag(MetaTag metatag)
          Add metatag to this image.
 boolean equals(Object obj)
           
 Album getAlbum()
           
 String getCameraModel()
           
 List<Comment> getComments()
           
 Date getCreated()
           
 String getDescription()
           
 String getFullPath()
          Return relative path of this image in file-system(relative to uploadRoot parameter)
 int getHeight()
           
 Long getId()
           
 List<MetaTag> getImageTags()
           
 String getMeta()
          Return Comma separated tag value for presentation in view
 String getMetaString()
          Getter for property meta
 String getName()
           
 User getOwner()
           
 String getPath()
          Getter for property path.
 Boolean getShowMetaInfo()
           
 double getSize()
          Getter for property size
 MetaTag getTagByName(String s)
          Return MetaTag object by string representation
 Date getUploaded()
          Getter for property uploaded
 int getWidth()
           
 int hashCode()
           
 boolean isAllowComments()
          Getter for property allowComments.
 boolean isCovering()
           
 boolean isNew()
          Determine if this image should be marked as new(on jsf page, for example in tree)
 boolean isOwner(User user)
           
 boolean isPreDefined()
          Getter for property preDefined
 boolean isVisited()
          Getter for property visited
 void removeComment(Comment comment)
          Remove comment from list of comments, belongs to that image.
 void removeMetaTag(MetaTag metatag)
          Remove metatag from list of metatag, associated to that image.
 void setAlbum(Album album)
           
 void setAllowComments(boolean allowComments)
           
 void setCameraModel(String cameraModel)
           
 void setCovering(boolean covering)
           
 void setCreated(Date created)
           
 void setDescription(String description)
           
 void setHeight(int height)
           
 void setImageTags(List<MetaTag> imageTags)
           
 void setMeta(String meta)
          Setter for property meta
 void setName(String name)
           
 void setPath(String path)
          Setter for property path
 void setShowMetaInfo(Boolean showMetaInfo)
           
 void setSize(double size)
          setter for property size
 void setUploaded(Date uploaded)
          setter for property uploaded
 void setVisited(boolean visited)
          Setter for property visited
 void setWidth(int width)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Image

public Image()
Method Detail

isPreDefined

public boolean isPreDefined()
Getter for property preDefined

Returns:
is this shelf is predefined

getShowMetaInfo

public Boolean getShowMetaInfo()

setShowMetaInfo

public void setShowMetaInfo(Boolean showMetaInfo)

getId

public Long getId()

getName

public String getName()

setName

public void setName(String name)

getDescription

public String getDescription()

setDescription

public void setDescription(String description)

getPath

public String getPath()
Getter for property path. Represent file-system structure, relative at uploadRoot dir(determined at startup, by default is system temp dir) Usually is user.GetLogin() + SLASH + image.getAlbum().getId() + SLASH + fileName, for example "amarkhel/15/coolPicture.jpg"

Returns:
relative path of image

setPath

public void setPath(String path)
Setter for property path

Parameters:
path - - relative path to image

getCreated

public Date getCreated()

setCreated

public void setCreated(Date created)

getAlbum

public Album getAlbum()

setAlbum

public void setAlbum(Album album)

getComments

public List<Comment> getComments()

getImageTags

public List<MetaTag> getImageTags()

setMeta

public void setMeta(String meta)
Setter for property meta

Parameters:
meta - - string representation of metatags, associated to image. Used at jsf page.

getMetaString

public String getMetaString()
Getter for property meta

Returns:
string representation of metatags, associated to image. Used at jsf page.

getCameraModel

public String getCameraModel()

setCameraModel

public void setCameraModel(String cameraModel)

getHeight

public int getHeight()

setHeight

public void setHeight(int height)

getSize

public double getSize()
Getter for property size

Returns:
size of image in KB

setSize

public void setSize(double size)
setter for property size

Parameters:
size - - size of image in KB

getWidth

public int getWidth()

setWidth

public void setWidth(int width)

getUploaded

public Date getUploaded()
Getter for property uploaded

Returns:
date of upload to site of this image

setUploaded

public void setUploaded(Date uploaded)
setter for property uploaded

Parameters:
uploaded - - date of upload

isAllowComments

public boolean isAllowComments()
Getter for property allowComments. If true, other user may comment this image.

Returns:
is other users may comment this image

setAllowComments

public void setAllowComments(boolean allowComments)
Parameters:
allowComments - the allowComments to set

isCovering

public boolean isCovering()
Returns:
if this image is covering for containing album

setImageTags

public void setImageTags(List<MetaTag> imageTags)

setCovering

public void setCovering(boolean covering)
Parameters:
covering - - determine if this image is covering for containing album

isVisited

public boolean isVisited()
Getter for property visited

Returns:
boolean value, that indicated is user visit this image already

setVisited

public void setVisited(boolean visited)
Setter for property visited

Parameters:
visited - - boolean value, that indicated is user visit this image already

isNew

public boolean isNew()
Determine if this image should be marked as new(on jsf page, for example in tree)

Returns:
boolean value, that indicated is this image should be marked as new

addComment

public void addComment(Comment comment)
Add comment to this image.

Parameters:
comment - - comment to add

removeComment

public void removeComment(Comment comment)
Remove comment from list of comments, belongs to that image.

Parameters:
comment - - comment to delete

addMetaTag

public void addMetaTag(MetaTag metatag)
Add metatag to this image.

Parameters:
metatag - - metatag to add

removeMetaTag

public void removeMetaTag(MetaTag metatag)
Remove metatag from list of metatag, associated to that image.

Parameters:
metatag - - metatag to delete

getTagByName

public MetaTag getTagByName(String s)
Return MetaTag object by string representation

Parameters:
s - - string representation of metatag

getMeta

public String getMeta()
Return Comma separated tag value for presentation in view


getFullPath

public String getFullPath()
Return relative path of this image in file-system(relative to uploadRoot parameter)


getOwner

public User getOwner()

isOwner

public boolean isOwner(User user)

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

RichFaces Photoalbum 4.3.5.Final

Copyright © 2014 JBoss by Red Hat. All Rights Reserved.