cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager Class Reference

Inheritance diagram for cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager:
Inheritance graph
[legend]
Collaboration diagram for cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 UserNodeManager (Collection userList, String loggedUserName)
void initChildrenMap (NodeMap nodeMap)
java.util.Comparator getComparator ()
void addConfiguration (BeanSupport conf) throws IntrospectionException
List getConfigurationNames (String userName)

Private Member Functions

ConfigurationBean findDefaultConfiguration ()

Private Attributes

final Logger logger
NodeMap confMap
Collection userList = null
String loggedUserName = null
GPNode loggedUserNode = null

Constructor & Destructor Documentation

cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager::UserNodeManager ( Collection  userList,
String  loggedUserName 
) [inline]
Parameters:
userList list with User objects
loggedUserNode 

Member Function Documentation

void cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager::addConfiguration ( BeanSupport  conf  )  throws IntrospectionException [inline]
ConfigurationBean cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager::findDefaultConfiguration (  )  [inline, private]
java.util.Comparator cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager::getComparator (  )  [inline]

Returns a comparator that can be used to sort the collection of nodes managed by this class. null can be returned to specify that the collection should not be sorted. If a comparator is returned it should be able to compare two nodes belonging to the children managed by this manager. An adapter can be used to deal with the bean associated to the node instead of the nodes itself.

Returns:
a comparator for the node or null
See also:
BeanComparatorAdapter

Implements cern::gp::nodes::children::ChildrenManager.

List cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager::getConfigurationNames ( String  userName  )  [inline]
void cern::laser::guiplatform::windows::user::UserExplorer::UserNodeManager::initChildrenMap ( NodeMap  nodeMap  )  [inline]

Receives the NodeMap that is managed by this manager and that can be used to add or remove children.

This method is called lazily once when the children are going to be displayed. It is similar to the addNotify() of a GUI component.

The implementation of this method should do two things. First it should initialize the map of children with the current children. For that it can use the method addNode of the nodeMap. Second, and only if the children are dynamic and are changing based on some external events, it should keep the reference to the given nodeMap for future use.

If the children are not dynamic, which means that they don't change after they have been initialized here, there is no need to keep a reference to the nodeMap.

Parameters:
nodeMap the map representing the children managed by this manager

Implements cern::gp::nodes::children::ChildrenMapManager.

References cern::gp::nodes::children::NodeMap::addNode(), confMap, cern::laser::guiplatform::user::UserBean::getConfigurations(), cern::gp::nodes::GPNode::getName(), cern::laser::console::User::getName(), logger, cern::laser::guiplatform::user::UserBean::setIsLogged(), and userList.


Member Data Documentation

configuration for given user

Referenced by addConfiguration(), findDefaultConfiguration(), getConfigurationNames(), and initChildrenMap().

logged user name

Referenced by addConfiguration(), and findDefaultConfiguration().

logged user node

Initial value:
        LogFactory.getLogger(UserNodeManager.class.getName())

Referenced by initChildrenMap().

user list

Referenced by initChildrenMap().


The documentation for this class was generated from the following file:

Generated by  doxygen 1.6.2