org.palo.api.ext.favoriteviews.impl
Class FavoriteViewsFolderImpl

java.lang.Object
  extended by org.palo.api.ext.favoriteviews.impl.FavoriteViewsFolderImpl
All Implemented Interfaces:
FavoriteViewObject, FavoriteViewsFolder, NamedEntity

public class FavoriteViewsFolderImpl
extends java.lang.Object
implements FavoriteViewsFolder

FavoriteViewsFolderImpl A folder is a container object with a name. It also holds a position information so that the user can place it anywhere she likes (in relation to its siblings in the tree). Furthermore the folder has information on the connection from which it was created. This is used to assign favorite view structures to specific connections. If a folder is being moved to a favorite view structure of a different connection, the transfer is aborted.

Version:
$Id: FavoriteViewsFolderImpl.html,v 1.8 2009/07/09 11:01:47 ArndHouben Exp $

Constructor Summary
FavoriteViewsFolderImpl(java.lang.String name, Connection con)
          Creates a new folder with the specified name and connection.
FavoriteViewsFolderImpl(java.lang.String name, Connection con, int position)
          Creates a new folder with the specified name and position.
 
Method Summary
 Connection getConnection()
          Returns the connection for this folder.
 java.lang.String getName()
          Returns the name of the folder.
 int getPosition()
          Returns the position of the folder.
 void setName(java.lang.String newName)
          Sets a new name for the folder.
 void setPosition(int newPosition)
          Sets a new position for the folder.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FavoriteViewsFolderImpl

public FavoriteViewsFolderImpl(java.lang.String name,
                               Connection con)
Creates a new folder with the specified name and connection.

Parameters:
name - the name of the folder.
con - the connection to which this bookmark folder belongs.

FavoriteViewsFolderImpl

public FavoriteViewsFolderImpl(java.lang.String name,
                               Connection con,
                               int position)
Creates a new folder with the specified name and position.

Parameters:
name - the name of the folder.
con - the connection to which this bookmark folder belongs.
position - the position in relation to its siblings.
Method Detail

getName

public java.lang.String getName()
Returns the name of the folder.

Specified by:
getName in interface NamedEntity
Returns:
the name of the entity.

setName

public void setName(java.lang.String newName)
Sets a new name for the folder.

Specified by:
setName in interface FavoriteViewsFolder
Parameters:
newName - the new name for the folder.

getPosition

public int getPosition()
Returns the position of the folder.

Specified by:
getPosition in interface FavoriteViewsFolder
Returns:
the position of this favorite views folder in relation to its parent.

setPosition

public void setPosition(int newPosition)
Sets a new position for the folder.

Specified by:
setPosition in interface FavoriteViewsFolder
Parameters:
newPosition - the new position for the folder.

getConnection

public Connection getConnection()
Returns the connection for this folder.

Specified by:
getConnection in interface FavoriteViewObject
Returns:
the connection for this folder.