📄 defaultlocalcachestrategy.html
字号:
<TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> byte[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../org/jivesoftware/util/cache/DefaultLocalCacheStrategy.html#getSeniorClusterMemberID()">getSeniorClusterMemberID</A></B>()</CODE><BR> Returns a byte[] that uniquely identifies this senior cluster member or <tt>null</tt> when not in a cluster.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../org/jivesoftware/util/cache/DefaultLocalCacheStrategy.html#isSeniorClusterMember()">isSeniorClusterMember</A></B>()</CODE><BR> Returns true if this node is the maste node of the cluster.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../org/jivesoftware/util/cache/DefaultLocalCacheStrategy.html#startCluster()">startCluster</A></B>()</CODE><BR> Returns true if the cluster has been started.</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="../../../../org/jivesoftware/util/cache/DefaultLocalCacheStrategy.html#stopCluster()">stopCluster</A></B>()</CODE><BR> Stops the cluster.</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="../../../../org/jivesoftware/util/cache/DefaultLocalCacheStrategy.html#updateCacheStats(java.util.Map)">updateCacheStats</A></B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/util/Map.html" title="class or interface in java.util">Map</A><<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>,<A HREF="../../../../org/jivesoftware/util/cache/Cache.html" title="interface in org.jivesoftware.util.cache">Cache</A>> caches)</CODE><BR> Updates the statistics of the specified caches and publishes them into a cache for statistics.</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"><TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A></B></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/j2se/1.5.0/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.5.0/docs/api/java/lang/Object.html#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.5.0/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.5.0/docs/api/java/lang/Object.html#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD></TR></TABLE> <P><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TH></TR></TABLE><A NAME="DefaultLocalCacheStrategy()"><!-- --></A><H3>DefaultLocalCacheStrategy</H3><PRE>public <B>DefaultLocalCacheStrategy</B>()</PRE><DL></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"><B>Method Detail</B></FONT></TH></TR></TABLE><A NAME="startCluster()"><!-- --></A><H3>startCluster</H3><PRE>public boolean <B>startCluster</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#startCluster()">CacheFactoryStrategy</A></CODE></B></DD><DD>Returns true if the cluster has been started. When running in local mode a true value should be returned.<p> An error should be logged when the cluster fails to be started.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#startCluster()">startCluster</A></CODE> in interface <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html" title="interface in org.jivesoftware.util.cache">CacheFactoryStrategy</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>true if the cluster has been started.</DL></DD></DL><HR><A NAME="stopCluster()"><!-- --></A><H3>stopCluster</H3><PRE>public void <B>stopCluster</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#stopCluster()">CacheFactoryStrategy</A></CODE></B></DD><DD>Stops the cluster. When not running in a cluster this request will be ignored.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#stopCluster()">stopCluster</A></CODE> in interface <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html" title="interface in org.jivesoftware.util.cache">CacheFactoryStrategy</A></CODE></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="createCache(java.lang.String)"><!-- --></A><H3>createCache</H3><PRE>public <A HREF="../../../../org/jivesoftware/util/cache/Cache.html" title="interface in org.jivesoftware.util.cache">Cache</A> <B>createCache</B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> name)</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#createCache(java.lang.String)">CacheFactoryStrategy</A></CODE></B></DD><DD>Creates a new cache for the cache name specified. The created cache is already configured. Different implementations could store the cache configuration in different ways. It is recommended to store the cache configuration in an external file so it is easier for customers to change the default configuration.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#createCache(java.lang.String)">createCache</A></CODE> in interface <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html" title="interface in org.jivesoftware.util.cache">CacheFactoryStrategy</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>name</CODE> - name of the cache to create.<DT><B>Returns:</B><DD>newly created and configured cache.</DL></DD></DL><HR><A NAME="destroyCache(org.jivesoftware.util.cache.Cache)"><!-- --></A><H3>destroyCache</H3><PRE>public void <B>destroyCache</B>(<A HREF="../../../../org/jivesoftware/util/cache/Cache.html" title="interface in org.jivesoftware.util.cache">Cache</A> cache)</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#destroyCache(org.jivesoftware.util.cache.Cache)">CacheFactoryStrategy</A></CODE></B></DD><DD>Destroys the supplied cache.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#destroyCache(org.jivesoftware.util.cache.Cache)">destroyCache</A></CODE> in interface <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html" title="interface in org.jivesoftware.util.cache">CacheFactoryStrategy</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>cache</CODE> - the cache to destroy.</DL></DD></DL><HR><A NAME="isSeniorClusterMember()"><!-- --></A><H3>isSeniorClusterMember</H3><PRE>public boolean <B>isSeniorClusterMember</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#isSeniorClusterMember()">CacheFactoryStrategy</A></CODE></B></DD><DD>Returns true if this node is the maste node of the cluster. When not running in cluster mode a value of true should be returned.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#isSeniorClusterMember()">isSeniorClusterMember</A></CODE> in interface <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html" title="interface in org.jivesoftware.util.cache">CacheFactoryStrategy</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>true if this node is the maste node of the cluster.</DL></DD></DL><HR><A NAME="getClusterNodesInfo()"><!-- --></A><H3>getClusterNodesInfo</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/util/Collection.html" title="class or interface in java.util">Collection</A><<A HREF="../../../../org/jivesoftware/openfire/cluster/ClusterNodeInfo.html" title="interface in org.jivesoftware.openfire.cluster">ClusterNodeInfo</A>> <B>getClusterNodesInfo</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#getClusterNodesInfo()">CacheFactoryStrategy</A></CODE></B></DD><DD>Returns basic information about the current members of the cluster or an empty collection if not running in a cluster.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#getClusterNodesInfo()">getClusterNodesInfo</A></CODE> in interface <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html" title="interface in org.jivesoftware.util.cache">CacheFactoryStrategy</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>information about the current members of the cluster or an empty collection if not running in a cluster.</DL></DD></DL><HR><A NAME="getMaxClusterNodes()"><!-- --></A><H3>getMaxClusterNodes</H3><PRE>public int <B>getMaxClusterNodes</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#getMaxClusterNodes()">CacheFactoryStrategy</A></CODE></B></DD><DD>Returns the maximum number of cluster members allowed. A value of 0 will be returned when clustering is not allowed.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#getMaxClusterNodes()">getMaxClusterNodes</A></CODE> in interface <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html" title="interface in org.jivesoftware.util.cache">CacheFactoryStrategy</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>the maximum number of cluster members allowed or 0 if clustering is not allowed.</DL></DD></DL><HR><A NAME="getSeniorClusterMemberID()"><!-- --></A><H3>getSeniorClusterMemberID</H3><PRE>public byte[] <B>getSeniorClusterMemberID</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/jivesoftware/util/cache/CacheFactoryStrategy.html#getSeniorClusterMemberID()">CacheFactoryStrategy</A></CODE></B></DD><DD>Returns a byte[] that uniquely identifies this senior cluster member or <tt>null</tt> when not in a cluster.<P>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -