⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 relationsupport.html

📁 j2ee的API 1.4版本,j2ee的帮助文档
💻 HTML
📖 第 1 页 / 共 5 页
字号:
                    <A HREF="../../../javax/management/relation/RelationNotFoundException.html" title="class in javax.management.relation">RelationNotFoundException</A></PRE><DL><DD>Sets the given role. <P>Will check the role according to its corresponding role definition provided in relation's relation type <P>Will send a notification (RelationNotification with type RELATION_BASIC_UPDATE or RELATION_MBEAN_UPDATE, depending if the relation is a MBean or not).<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../javax/management/relation/Relation.html#setRole(javax.management.relation.Role)">setRole</A></CODE> in interface <CODE><A HREF="../../../javax/management/relation/Relation.html" title="interface in javax.management.relation">Relation</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>theRole</CODE> - role to be set (name and new value)<DT><B>Throws:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/IllegalArgumentException.html" title="class or interface in java.lang">IllegalArgumentException</A></CODE> - if null role<DD><CODE><A HREF="../../../javax/management/relation/RoleNotFoundException.html" title="class in javax.management.relation">RoleNotFoundException</A></CODE> - if the role is not writable (no test on the write access mode performed when initialising the role)<DD><CODE><A HREF="../../../javax/management/relation/InvalidRoleValueException.html" title="class in javax.management.relation">InvalidRoleValueException</A></CODE> - if value provided for role is not valid, i.e.: <P>- the number of referenced MBeans in given value is less than expected minimum degree <P>- the number of referenced MBeans in provided value exceeds expected maximum degree <P>- one referenced MBean in the value is not an Object of the MBean class expected for that role <P>- a MBean provided for that role does not exist<DD><CODE><A HREF="../../../javax/management/relation/RelationServiceNotRegisteredException.html" title="class in javax.management.relation">RelationServiceNotRegisteredException</A></CODE> - if the Relation Service is not registered in the MBean Server<DD><CODE><A HREF="../../../javax/management/relation/RelationTypeNotFoundException.html" title="class in javax.management.relation">RelationTypeNotFoundException</A></CODE> - if the relation type has not been declared in the Relation Service<DD><CODE><A HREF="../../../javax/management/relation/RelationNotFoundException.html" title="class in javax.management.relation">RelationNotFoundException</A></CODE> - if the relation has not been added in the Relation Service.<DT><B>See Also:</B><DD><A HREF="../../../javax/management/relation/RelationSupport.html#getRole(java.lang.String)"><CODE>getRole(java.lang.String)</CODE></A></DL></DD></DL><HR><A NAME="setRoles(javax.management.relation.RoleList)"><!-- --></A><H3>setRoles</H3><PRE>public <A HREF="../../../javax/management/relation/RoleResult.html" title="class in javax.management.relation">RoleResult</A> <B>setRoles</B>(<A HREF="../../../javax/management/relation/RoleList.html" title="class in javax.management.relation">RoleList</A>&nbsp;theRoleList)                    throws <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/IllegalArgumentException.html" title="class or interface in java.lang">IllegalArgumentException</A>,                           <A HREF="../../../javax/management/relation/RelationServiceNotRegisteredException.html" title="class in javax.management.relation">RelationServiceNotRegisteredException</A>,                           <A HREF="../../../javax/management/relation/RelationTypeNotFoundException.html" title="class in javax.management.relation">RelationTypeNotFoundException</A>,                           <A HREF="../../../javax/management/relation/RelationNotFoundException.html" title="class in javax.management.relation">RelationNotFoundException</A></PRE><DL><DD>Sets the given roles. <P>Will check the role according to its corresponding role definition provided in relation's relation type <P>Will send one notification (RelationNotification with type RELATION_BASIC_UPDATE or RELATION_MBEAN_UPDATE, depending if the relation is a MBean or not) per updated role.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../javax/management/relation/Relation.html#setRoles(javax.management.relation.RoleList)">setRoles</A></CODE> in interface <CODE><A HREF="../../../javax/management/relation/Relation.html" title="interface in javax.management.relation">Relation</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>theRoleList</CODE> - list of roles to be set<DT><B>Returns:</B><DD>a RoleResult object, including a RoleList (for roles succcessfully set) and a RoleUnresolvedList (for roles not set).<DT><B>Throws:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/IllegalArgumentException.html" title="class or interface in java.lang">IllegalArgumentException</A></CODE> - if null role name<DD><CODE><A HREF="../../../javax/management/relation/RelationServiceNotRegisteredException.html" title="class in javax.management.relation">RelationServiceNotRegisteredException</A></CODE> - if the Relation Service is not registered in the MBean Server<DD><CODE><A HREF="../../../javax/management/relation/RelationTypeNotFoundException.html" title="class in javax.management.relation">RelationTypeNotFoundException</A></CODE> - if the relation type has not been declared in the Relation Service.<DD><CODE><A HREF="../../../javax/management/relation/RelationNotFoundException.html" title="class in javax.management.relation">RelationNotFoundException</A></CODE> - if the relation MBean has not been added in the Relation Service.<DT><B>See Also:</B><DD><A HREF="../../../javax/management/relation/RelationSupport.html#getRoles(java.lang.String[])"><CODE>getRoles(java.lang.String[])</CODE></A></DL></DD></DL><HR><A NAME="handleMBeanUnregistration(javax.management.ObjectName, java.lang.String)"><!-- --></A><H3>handleMBeanUnregistration</H3><PRE>public void <B>handleMBeanUnregistration</B>(<A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A>&nbsp;theObjName,                                      <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;theRoleName)                               throws <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/IllegalArgumentException.html" title="class or interface in java.lang">IllegalArgumentException</A>,                                      <A HREF="../../../javax/management/relation/RoleNotFoundException.html" title="class in javax.management.relation">RoleNotFoundException</A>,                                      <A HREF="../../../javax/management/relation/InvalidRoleValueException.html" title="class in javax.management.relation">InvalidRoleValueException</A>,                                      <A HREF="../../../javax/management/relation/RelationServiceNotRegisteredException.html" title="class in javax.management.relation">RelationServiceNotRegisteredException</A>,                                      <A HREF="../../../javax/management/relation/RelationTypeNotFoundException.html" title="class in javax.management.relation">RelationTypeNotFoundException</A>,                                      <A HREF="../../../javax/management/relation/RelationNotFoundException.html" title="class in javax.management.relation">RelationNotFoundException</A></PRE><DL><DD>Callback used by the Relation Service when a MBean referenced in a role is unregistered. <P>The Relation Service will call this method to let the relation take action to reflect the impact of such unregistration. <P>BEWARE. the user is not expected to call this method. <P>Current implementation is to set the role with its current value (list of ObjectNames of referenced MBeans) without the unregistered one.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../javax/management/relation/Relation.html#handleMBeanUnregistration(javax.management.ObjectName, java.lang.String)">handleMBeanUnregistration</A></CODE> in interface <CODE><A HREF="../../../javax/management/relation/Relation.html" title="interface in javax.management.relation">Relation</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>theObjName</CODE> - ObjectName of unregistered MBean<DD><CODE>theRoleName</CODE> - name of role where the MBean is referenced<DT><B>Throws:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/IllegalArgumentException.html" title="class or interface in java.lang">IllegalArgumentException</A></CODE> - if null parameter<DD><CODE><A HREF="../../../javax/management/relation/RoleNotFoundException.html" title="class in javax.management.relation">RoleNotFoundException</A></CODE> - if role does not exist in the relation or is not writable<DD><CODE><A HREF="../../../javax/management/relation/InvalidRoleValueException.html" title="class in javax.management.relation">InvalidRoleValueException</A></CODE> - if role value does not conform to the associated role info (this will never happen when called from the Relation Service)<DD><CODE><A HREF="../../../javax/management/relation/RelationServiceNotRegisteredException.html" title="class in javax.management.relation">RelationServiceNotRegisteredException</A></CODE> - if the Relation Service is not registered in the MBean Server<DD><CODE><A HREF="../../../javax/management/relation/RelationTypeNotFoundException.html" title="class in javax.management.relation">RelationTypeNotFoundException</A></CODE> - if the relation type has not been declared in the Relation Service.<DD><CODE><A HREF="../../../javax/management/relation/RelationNotFoundException.html" title="class in javax.management.relation">RelationNotFoundException</A></CODE> - if this method is called for a relation MBean not added in the Relation Service.</DL></DD></DL><HR><A NAME="getReferencedMBeans()"><!-- --></A><H3>getReferencedMBeans</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Map.html" title="class or interface in java.util">Map</A> <B>getReferencedMBeans</B>()</PRE><DL><DD>Retrieves MBeans referenced in the various roles of the relation.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../javax/management/relation/Relation.html#getReferencedMBeans()">getReferencedMBeans</A></CODE> in interface <CODE><A HREF="../../../javax/management/relation/Relation.html" title="interface in javax.management.relation">Relation</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>a HashMap mapping: <P> ObjectName -> ArrayList of String (role names)</DL></DD></DL><HR><A NAME="getRelationTypeName()"><!-- --></A><H3>getRelationTypeName</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> <B>getRelationTypeName</B>()</PRE><DL><DD>Returns name of associated relation type.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../javax/management/relation/Relation.html#getRelationTypeName()">getRelationTypeName</A></CODE> in interface <CODE><A HREF="../../../javax/management/relation/Relation.html" title="interface in javax.management.relation">Relation</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>the name of the relation type.</DL></DD></DL><HR><A NAME="getRelationServiceName()"><!-- --></A><H3>getRelationServiceName</H3><PRE>public <A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A> <B>getRelationServiceName</B>()</PRE><DL><DD>Returns ObjectName of the Relation Service handling the relation.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../javax/management/relation/Relation.html#getRelationServiceName()">getRelationServiceName</A></CODE> in interface <CODE><A HREF="../../../javax/management/relation/Relation.html" title="interface in javax.management.relation">Relation</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>the ObjectName of the Relation Service.</DL></DD></DL><HR><A NAME="getRelationId()"><!-- --></A><H3>getRelationId</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> <B>getRelationId</B>()</PRE><DL><DD>Returns relation identifier (used to uniquely identify the relation inside the Relation Service).<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../javax/management/relation/Relation.html#getRelationId()">getRelationId</A></CODE> in interface <CODE><A HREF="../../../javax/management/relation/Relation.html" title="interface in javax.management.relation">Relation</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>the relation id.</DL></DD></DL><HR><A NAME="preRegister(javax.management.MBeanServer, javax.management.ObjectName)"><!-- --></A><H3>preRegister</H3><PRE>public <A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A> <B>preRegister</B>(<A HREF="../../../javax/management/MBeanServer.html" title="interface in javax.management">MBeanServer</A>&nbsp;server,                              <A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A>&nbsp;name)                       throws <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Exception.html" title="class or interface in java.lang">Exception</A></PRE><DL>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -