API Overview API Index Package Overview Direct link to this page
JDK 1.6
  javax.management.relation. RelationService View Source
Author(s)
Since
1.5
Version
Serial
Hierarchy
 Object
      NotificationBroadcasterSupport
          RelationService
Implements
 RelationServiceMBean
 MBeanRegistration
 NotificationListener
Subclasses
Description
public class RelationService
  The Relation Service is in charge of creating and deleting relation types and relations, of handling the consistency and of providing query mechanisms.
See also:   
Constructors
public RelationService (boolean immediatePurgeFlag)
  Constructor.
Methods
Hide/Show inherited methods
public void addNotificationListener (NotificationListener listener, NotificationFilter filter, Object handback) [Inherited From NotificationBroadcasterSupport]
  Adds a listener.
public void addRelation (ObjectName relationObjectName) throws IllegalArgumentException RelationServiceNotRegisteredException NoSuchMethodException InvalidRelationIdException InstanceNotFoundException InvalidRelationServiceException RelationTypeNotFoundException RoleNotFoundException InvalidRoleValueException [Specified in RelationServiceMBean]
  Adds an MBean created by the user (and registered by him in the MBean Server) as a relation in the Relation Service.
public void addRelationType (RelationType relationTypeObj) throws IllegalArgumentException InvalidRelationTypeException [Specified in RelationServiceMBean]
  Adds given object as a relation type.
public Integer checkRoleReading (String roleName, String relationTypeName) throws IllegalArgumentException RelationTypeNotFoundException [Specified in RelationServiceMBean]
  Checks if given Role can be read in a relation of the given type.
public Integer checkRoleWriting (Role role, String relationTypeName, Boolean initFlag) throws IllegalArgumentException RelationTypeNotFoundException [Specified in RelationServiceMBean]
  Checks if given Role can be set in a relation of given type.
public void createRelation (String relationId, String relationTypeName, RoleList roleList) throws RelationServiceNotRegisteredException IllegalArgumentException RoleNotFoundException InvalidRelationIdException RelationTypeNotFoundException InvalidRoleValueException [Specified in RelationServiceMBean]
  Creates a simple relation (represented by a RelationSupport object) of given relation type, and adds it in the Relation Service.
public void createRelationType (String relationTypeName, RoleInfo roleInfoArray) throws IllegalArgumentException InvalidRelationTypeException [Specified in RelationServiceMBean]
  Creates a relation type (a RelationTypeSupport object) with given role infos (provided by the RoleInfo objects), and adds it in the Relation Service.
public Map<ObjectName, List<String>> findAssociatedMBeans (ObjectName mbeanName, String relationTypeName, String roleName) throws IllegalArgumentException [Specified in RelationServiceMBean]
  Retrieves the MBeans associated to given one in a relation.
public Map<String, List<String>> findReferencingRelations (ObjectName mbeanName, String relationTypeName, String roleName) throws IllegalArgumentException [Specified in RelationServiceMBean]
  Retrieves the relations where a given MBean is referenced.
public List<String> findRelationsOfType (String relationTypeName) throws IllegalArgumentException RelationTypeNotFoundException [Specified in RelationServiceMBean]
  Returns the relation ids for relations of the given type.
public List<String> getAllRelationIds () [Specified in RelationServiceMBean]
  Returns all the relation ids for all the relations handled by the Relation Service.
public List<String> getAllRelationTypeNames () [Specified in RelationServiceMBean]
  Retrieves names of all known relation types.
public RoleResult getAllRoles (String relationId) throws IllegalArgumentException RelationNotFoundException RelationServiceNotRegisteredException [Specified in RelationServiceMBean]
  Returns all roles present in the relation.
public MBeanNotificationInfo getNotificationInfo () [Overrides NotificationBroadcasterSupport]
Returns a NotificationInfo object containing the name of the Java class of the notification and the notification types sent.
public boolean getPurgeFlag () [Specified in RelationServiceMBean]
  Returns the flag to indicate if when a notification is received for the unregistration of an MBean referenced in a relation, if an immediate "purge" of the relations (look for the relations no longer valid) has to be performed , or if that will be performed only when the purgeRelations method will be explicitly called.
public Map<ObjectName, List<String>> getReferencedMBeans (String relationId) throws IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Retrieves MBeans referenced in the various roles of the relation.
pack-private Object getRelation (String relationId) throws IllegalArgumentException RelationNotFoundException
pack-private RelationType getRelationType (String relationTypeName) throws IllegalArgumentException RelationTypeNotFoundException
public String getRelationTypeName (String relationId) throws IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Returns name of associated relation type for given relation.
public List<ObjectName> getRole (String relationId, String roleName) throws RelationServiceNotRegisteredException IllegalArgumentException RelationNotFoundException RoleNotFoundException [Specified in RelationServiceMBean]
  Retrieves role value for given role name in given relation.
public Integer getRoleCardinality (String relationId, String roleName) throws IllegalArgumentException RelationNotFoundException RoleNotFoundException [Specified in RelationServiceMBean]
  Retrieves the number of MBeans currently referenced in the given role.
public RoleInfo getRoleInfo (String relationTypeName, String roleInfoName) throws IllegalArgumentException RelationTypeNotFoundException RoleInfoNotFoundException [Specified in RelationServiceMBean]
  Retrieves role info for given role name of a given relation type.
public List<RoleInfo> getRoleInfos (String relationTypeName) throws IllegalArgumentException RelationTypeNotFoundException [Specified in RelationServiceMBean]
  Retrieves list of role infos (RoleInfo objects) of a given relation type.
public RoleResult getRoles (String relationId, String roleNameArray) throws RelationServiceNotRegisteredException IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Retrieves values of roles with given names in given relation.
protected void handleNotification (NotificationListener listener, Notification notif, Object handback) [Inherited From NotificationBroadcasterSupport]
  This method is called by sendNotification for each listener in order to send the notification to that listener.
public void handleNotification (Notification notif, Object handback) [Specified in NotificationListener]
  Invoked when a JMX notification occurs.
public Boolean hasRelation (String relationId) throws IllegalArgumentException [Specified in RelationServiceMBean]
  Checks if there is a relation identified in Relation Service with given relation id.
public void isActive () throws RelationServiceNotRegisteredException [Specified in RelationServiceMBean]
  Checks if the Relation Service is active.
public String isRelation (ObjectName objectName) throws IllegalArgumentException [Specified in RelationServiceMBean]
  Returns the relation id associated to the given ObjectName if the MBean has been added as a relation in the Relation Service.
public ObjectName isRelationMBean (String relationId) throws IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  If the relation is represented by an MBean (created by the user and added as a relation in the Relation Service), returns the ObjectName of the MBean.
public void postDeregister () [Specified in MBeanRegistration]
public void postRegister (Boolean registrationDone) [Specified in MBeanRegistration]
public void preDeregister () throws Exception [Specified in MBeanRegistration]
public ObjectName preRegister (MBeanServer server, ObjectName name) throws Exception [Specified in MBeanRegistration]
public void purgeRelations () throws RelationServiceNotRegisteredException [Specified in RelationServiceMBean]
  Purges the relations.
public void removeNotificationListener (NotificationListener listener) throws ListenerNotFoundException [Inherited From NotificationBroadcasterSupport]
public void removeNotificationListener (NotificationListener listener, NotificationFilter filter, Object handback) throws ListenerNotFoundException [Inherited From NotificationBroadcasterSupport]
public void removeRelation (String relationId) throws RelationServiceNotRegisteredException IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Removes given relation from the Relation Service.
public void removeRelationType (String relationTypeName) throws RelationServiceNotRegisteredException IllegalArgumentException RelationTypeNotFoundException [Specified in RelationServiceMBean]
  Removes given relation type from Relation Service.
public void sendNotification (Notification notification) [Inherited From NotificationBroadcasterSupport]
  Sends a notification.
public void sendRelationCreationNotification (String relationId) throws IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Sends a notification (RelationNotification) for a relation creation.
public void sendRelationRemovalNotification (String relationId, List<ObjectName> unregMBeanList) throws IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Sends a notification (RelationNotification) for a relation removal.
public void sendRoleUpdateNotification (String relationId, Role newRole, List<ObjectName> oldValue) throws IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Sends a notification (RelationNotification) for a role update in the given relation.
public void setPurgeFlag (boolean purgeFlag) [Specified in RelationServiceMBean]
  Sets the flag to indicate if when a notification is received for the unregistration of an MBean referenced in a relation, if an immediate "purge" of the relations (look for the relations no longer valid) has to be performed , or if that will be performed only when the purgeRelations method will be explicitly called.
public void setRole (String relationId, Role role) throws RelationServiceNotRegisteredException IllegalArgumentException RelationNotFoundException RoleNotFoundException InvalidRoleValueException [Specified in RelationServiceMBean]
  Sets the given role in given relation.
public RoleResult setRoles (String relationId, RoleList roleList) throws RelationServiceNotRegisteredException IllegalArgumentException RelationNotFoundException [Specified in RelationServiceMBean]
  Sets the given roles in given relation.
pack-privatestatic void throwRoleProblemException (int pbType, String roleName) throws IllegalArgumentException RoleNotFoundException InvalidRoleValueException
public void updateRoleMap (String relationId, Role newRole, List<ObjectName> oldValue) throws IllegalArgumentException RelationServiceNotRegisteredException RelationNotFoundException [Specified in RelationServiceMBean]
  Handles update of the Relation Service role map for the update of given role in given relation.
Fields
Hide/Show inherited fields
Nested Classes
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar