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

📄 timermbean.html

📁 j2ee api,很好的api。我这现在有
💻 HTML
📖 第 1 页 / 共 4 页
字号:
                  is scheduled with a <i>fixed-delay</i> execution scheme. Ignored if the                  notification is not periodic.<DT><B>Returns:</B><DD>The identifier of the new created timer notification.<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> - The period or the number of occurences is negative<DT><B>See Also:</B><DD><A HREF="../../../javax/management/timer/TimerMBean.html#addNotification(java.lang.String, java.lang.String, java.lang.Object, java.util.Date, long, long)"><CODE>addNotification(String, String, Object, Date, long, long)</CODE></A></DL></DD></DL><HR><A NAME="addNotification(java.lang.String, java.lang.String, java.lang.Object, java.util.Date, long, long)"><!-- --></A><H3>addNotification</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Integer.html" title="class or interface in java.lang">Integer</A> <B>addNotification</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>&nbsp;type,                               <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;message,                               <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A>&nbsp;userData,                               <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Date.html" title="class or interface in java.util">Date</A>&nbsp;date,                               long&nbsp;period,                               long&nbsp;nbOccurences)                        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></PRE><DL><DD>Creates a new timer notification with the specified <CODE>type</CODE>, <CODE>message</CODE>  and <CODE>userData</CODE> and inserts it into the list of notifications with a given date,  period and number of occurences. <P> If the timer notification to be inserted has a date that is before the current date, the method behaves as if the specified date were the current date. <BR> For once-off notifications, the notification is delivered immediately. <BR> For periodic notifications, the first notification is delivered immediately and the subsequent ones are spaced as specified by the period parameter.  <P> Note that once the timer notification has been added into the list of notifications, its associated date, period and number of occurences cannot be updated. <P> In the case of a periodic notification, uses a <i>fixed-delay</i> execution scheme, as specified in <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Timer.html" title="class or interface in java.util"><CODE>Timer</CODE></A>. In order to use a <i>fixed-rate</i> execution scheme, use  <A HREF="../../../javax/management/timer/TimerMBean.html#addNotification(java.lang.String, java.lang.String, java.lang.Object, java.util.Date, long, long, boolean)"><CODE>addNotification(String, String, Object, Date, long, long, boolean)</CODE></A> instead.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>type</CODE> - The timer notification type.<DD><CODE>message</CODE> - The timer notification detailed message.<DD><CODE>userData</CODE> - The timer notification user data object.<DD><CODE>date</CODE> - The date when the notification occurs.<DD><CODE>period</CODE> - The period of the timer notification (in milliseconds).<DD><CODE>nbOccurences</CODE> - The total number the timer notification will be emitted.<DT><B>Returns:</B><DD>The identifier of the new created timer notification.<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> - The period or the number of occurences is negative<DT><B>See Also:</B><DD><A HREF="../../../javax/management/timer/TimerMBean.html#addNotification(java.lang.String, java.lang.String, java.lang.Object, java.util.Date, long, long, boolean)"><CODE>addNotification(String, String, Object, Date, long, long, boolean)</CODE></A></DL></DD></DL><HR><A NAME="addNotification(java.lang.String, java.lang.String, java.lang.Object, java.util.Date, long)"><!-- --></A><H3>addNotification</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Integer.html" title="class or interface in java.lang">Integer</A> <B>addNotification</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>&nbsp;type,                               <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;message,                               <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A>&nbsp;userData,                               <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Date.html" title="class or interface in java.util">Date</A>&nbsp;date,                               long&nbsp;period)                        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></PRE><DL><DD>Creates a new timer notification with the specified <CODE>type</CODE>, <CODE>message</CODE>  and <CODE>userData</CODE> and inserts it into the list of notifications with a given date and period and a null number of occurences. <P> The timer notification will repeat continuously using the timer period using a <i>fixed-delay</i> execution scheme, as specified in <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Timer.html" title="class or interface in java.util"><CODE>Timer</CODE></A>. In order to use a <i>fixed-rate</i> execution scheme, use <A HREF="../../../javax/management/timer/TimerMBean.html#addNotification(java.lang.String, java.lang.String, java.lang.Object, java.util.Date, long, long, boolean)"><CODE>addNotification(String, String, Object, Date, long, long, boolean)</CODE></A> instead.  <P> If the timer notification to be inserted has a date that is before the current date, the method behaves as if the specified date were the current date. The first notification is delivered immediately and the subsequent ones are spaced as specified by the period parameter.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>type</CODE> - The timer notification type.<DD><CODE>message</CODE> - The timer notification detailed message.<DD><CODE>userData</CODE> - The timer notification user data object.<DD><CODE>date</CODE> - The date when the notification occurs.<DD><CODE>period</CODE> - The period of the timer notification (in milliseconds).<DT><B>Returns:</B><DD>The identifier of the new created timer notification.<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> - The period is negative or the date notification is before the current date.</DL></DD></DL><HR><A NAME="addNotification(java.lang.String, java.lang.String, java.lang.Object, java.util.Date)"><!-- --></A><H3>addNotification</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Integer.html" title="class or interface in java.lang">Integer</A> <B>addNotification</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>&nbsp;type,                               <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;message,                               <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A>&nbsp;userData,                               <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Date.html" title="class or interface in java.util">Date</A>&nbsp;date)                        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></PRE><DL><DD>Creates a new timer notification with the specified <CODE>type</CODE>, <CODE>message</CODE>  and <CODE>userData</CODE> and inserts it into the list of notifications with a given date and a null period and number of occurences. <P> The timer notification will be handled once at the specified date. <P> If the timer notification to be inserted has a date that is before the current date, the method behaves as if the specified date were the current date and the notification is delivered immediately.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>type</CODE> - The timer notification type.<DD><CODE>message</CODE> - The timer notification detailed message.<DD><CODE>userData</CODE> - The timer notification user data object.<DD><CODE>date</CODE> - The date when the notification occurs.<DT><B>Returns:</B><DD>The identifier of the new created timer notification.<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> - The date notification is before the current date.</DL></DD></DL><HR><A NAME="removeNotification(java.lang.Integer)"><!-- --></A><H3>removeNotification</H3><PRE>public void <B>removeNotification</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Integer.html" title="class or interface in java.lang">Integer</A>&nbsp;id)                        throws <A HREF="../../../javax/management/InstanceNotFoundException.html" title="class in javax.management">InstanceNotFoundException</A></PRE><DL><DD>Removes the timer notification corresponding to the specified identifier from the list of notifications.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>id</CODE> - The timer notification identifier.<DT><B>Throws:</B><DD><CODE><A HREF="../../../javax/management/InstanceNotFoundException.html" title="class in javax.management">InstanceNotFoundException</A></CODE> - The specified identifier does not correspond to any timer notification in the list of notifications of this timer MBean.</DL></DD></DL><HR><A NAME="removeNotifications(java.lang.String)"><!-- --></A><H3>removeNotifications</H3><PRE>public void <B>removeNotifications</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>&nbsp;type)                         throws <A HREF="../../../javax/management/InstanceNotFoundException.html" title="class in javax.management">InstanceNotFoundException</A></PRE><DL><DD>Removes all the timer notifications corresponding to the specified type from the list of notifications.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>type</CODE> - The timer notification type.<DT><B>Throws:</B><DD><CODE><A HREF="../../../javax/management/InstanceNotFoundException.html" title="class in javax.management">InstanceNotFoundException</A></CODE> - The specified type does not correspond to any timer notification in the list of notifications of this timer MBean.</DL></DD></DL><HR><A NAME="removeAllNotifications()"><!-- --></A><H3>removeAllNotifications</H3><PRE>public void <B>removeAllNotifications</B>()</PRE><DL><DD>Removes all the timer notifications from the list of notifications and resets the counter used to update the timer notification identifiers.<P><DD><DL></DL></DD></DL><HR><A NAME="getNbNotifications()"><!-- --></A><H3>getNbNotifications</H3><PRE>public int <B>getNbNotifications</B>()</PRE><DL><DD>Gets the number of timer notifications registered into the list of notifications.<P><DD><DL><DT><B>Returns:</B><DD>The number of timer notifications.</DL></DD></DL><HR><A NAME="getAllNotificationIDs()"><!-- --></A><H3>getAllNotificationIDs</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Vector.html" title="class or interface in java.util">Vector</A> <B>getAllNotificationIDs</B>()</PRE><DL><DD>Gets all timer notification identifiers registered into the list of notifications.<P><DD><DL><DT><B>Returns:</B><DD>A vector of <CODE>Integer</CODE> objects containing all the timer notification identifiers. <BR>The vector is empty if there is no timer notification registered for this timer MBean.</DL></DD></DL><HR><A NAME="getNotificationIDs(java.lang.String)"><!-- --></A><H3>getNotificationIDs</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Vector.html" title="class or interface in java.util">Vector</A> <B>getNotificationIDs</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>&nbsp;type)</PRE><DL><DD>Gets all the identifiers of timer notifications corresponding to the specified type.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>type</CODE> - The timer notification type.<DT><B>Returns:</B><DD>A vector of <CODE>Integer</CODE> objects containing all the identifiers of  timer notifications with the specified <CODE>type</CODE>. <BR>The vector is empty if there is no timer notifications registered for this timer MBean  with the specified <CODE>type</CODE>.</DL></DD></DL><HR><A NAME="getNotificationType(java.lang.Integer)"><!-- --></A><H3>getNotificationType</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>getNotificationType</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Integer.html" title="class or interface in java.lang">Integer</A>&nbsp;id)</PRE><DL><DD>Gets the timer notification type corresponding to the specified identifier.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>id</CODE> - The timer notification identifier.<DT><B>Returns:</B><DD>The timer notification type or null if the identifier is not mapped to any  timer notification registered for this timer MBean.</DL>

⌨️ 快捷键说明

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