📄 relationsupport.html
字号:
<TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#getRelationServiceName()">getRelationServiceName</A></B>()</CODE><BR> Returns ObjectName of the Relation Service handling the relation.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#getRelationTypeName()">getRelationTypeName</A></B>()</CODE><BR> Returns name of associated relation type.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/List.html" title="class or interface in java.util">List</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#getRole(java.lang.String)">getRole</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> theRoleName)</CODE><BR> Retrieves role value for given role name. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Integer.html" title="class or interface in java.lang">Integer</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#getRoleCardinality(java.lang.String)">getRoleCardinality</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> theRoleName)</CODE><BR> Returns the number of MBeans currently referenced in the given role.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/management/relation/RoleResult.html" title="class in javax.management.relation">RoleResult</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#getRoles(java.lang.String[])">getRoles</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>[] theRoleNameArray)</CODE><BR> Retrieves values of roles with given names. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#handleMBeanUnregistration(javax.management.ObjectName, java.lang.String)">handleMBeanUnregistration</A></B>(<A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A> 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> theRoleName)</CODE><BR> Callback used by the Relation Service when a MBean referenced in a role is unregistered. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Boolean.html" title="class or interface in java.lang">Boolean</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#isInRelationService()">isInRelationService</A></B>()</CODE><BR> Returns an internal flag specifying if the object is still handled by the Relation Service.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#postDeregister()">postDeregister</A></B>()</CODE><BR> Allows the MBean to perform any operations needed after having been unregistered in the MBean server.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#postRegister(java.lang.Boolean)">postRegister</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Boolean.html" title="class or interface in java.lang">Boolean</A> registrationDone)</CODE><BR> Allows the MBean to perform any operations needed after having been registered in the MBean server or after the registration has failed.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#preDeregister()">preDeregister</A></B>()</CODE><BR> Allows the MBean to perform any operations it needs before being unregistered by the MBean server.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#preRegister(javax.management.MBeanServer, javax.management.ObjectName)">preRegister</A></B>(<A HREF="../../../javax/management/MBeanServer.html" title="interface in javax.management">MBeanServer</A> server, <A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A> name)</CODE><BR> Allows the MBean to perform any operations it needs before being registered in the MBean server. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/management/relation/RoleList.html" title="class in javax.management.relation">RoleList</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#retrieveAllRoles()">retrieveAllRoles</A></B>()</CODE><BR> Returns all roles in the relation without checking read mode.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#setRelationServiceManagementFlag(java.lang.Boolean)">setRelationServiceManagementFlag</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Boolean.html" title="class or interface in java.lang">Boolean</A> theFlg)</CODE><BR> Specifies whether this relation is handled by the Relation Service.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#setRole(javax.management.relation.Role)">setRole</A></B>(<A HREF="../../../javax/management/relation/Role.html" title="class in javax.management.relation">Role</A> theRole)</CODE><BR> Sets the given role. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/management/relation/RoleResult.html" title="class in javax.management.relation">RoleResult</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/management/relation/RelationSupport.html#setRoles(javax.management.relation.RoleList)">setRoles</A></B>(<A HREF="../../../javax/management/relation/RoleList.html" title="class in javax.management.relation">RoleList</A> theRoleList)</CODE><BR> Sets the given roles. </TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="RelationSupport(java.lang.String, javax.management.ObjectName, java.lang.String, javax.management.relation.RoleList)"><!-- --></A><H3>RelationSupport</H3><PRE>public <B>RelationSupport</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> theRelId, <A HREF="../../../javax/management/ObjectName.html" title="class in javax.management">ObjectName</A> theRelServiceName, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> theRelTypeName, <A HREF="../../../javax/management/relation/RoleList.html" title="class in javax.management.relation">RoleList</A> theRoleList) throws <A HREF="../../../javax/management/relation/InvalidRoleValueException.html" title="class in javax.management.relation">InvalidRoleValueException</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/IllegalArgumentException.html" title="class or interface in java.lang">IllegalArgumentException</A></PRE><DL><DD>Creates object. <P>This constructor has to be used when the RelationSupport object will be registered as a MBean by the user, or when creating a user relation MBean those class extends RelationSupport. <P>Nothing is done at the Relation Service level, i.e. the RelationSupport object is not added, and no check if the provided values are correct. The object is always created, EXCEPT if: <P>- one mandatory parameter is not provided <P>- the same name is used for two roles. <P>To be handled as a relation, the object has then to be added in the Relation Service using Relation Service method addRelation().<P><DT><B>Parameters:</B><DD><CODE>theRelId</CODE> - relation identifier, to identify the relation in the Relation Service. <P>Expected to be unique in the given Relation Service.<DD><CODE>theRelServiceName</CODE> - ObjectName of the Relation Service where the relation will be registered. <P>It is required as this is the Relation Service that is aware of the definition of the relation type of given relation, so that will be able to check update operations (set).<DD><CODE>theRelTypeName</CODE> - Name of relation type. <P>Expected to have been created in given Relation Service.<DD><CODE>theRoleList</CODE> - list of roles (Role objects) to initialised the relation. Can be null. <P>Expected to conform to relation info in associated relation type.<DT><B>Throws:</B>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -