📄 shutdowncontroller.html
字号:
<DD>Use this constant with <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method to power off computer.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#com.qotsa.controller.ShutDownController.POWEROFF">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="RESTART"><!-- --></A><H3>
RESTART</H3>
<PRE>
public static final char <B>RESTART</B></PRE>
<DL>
<DD>Use this constant with <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method to restart computer.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#com.qotsa.controller.ShutDownController.RESTART">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="LOGOFF"><!-- --></A><H3>
LOGOFF</H3>
<PRE>
public static final char <B>LOGOFF</B></PRE>
<DL>
<DD>Use this constant with <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method to log off user.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#com.qotsa.controller.ShutDownController.LOGOFF">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ABORT"><!-- --></A><H3>
ABORT</H3>
<PRE>
public static final char <B>ABORT</B></PRE>
<DL>
<DD>Use this constant with <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method to abort a Power Off or Restart operation.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#com.qotsa.controller.ShutDownController.ABORT">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="LOCK"><!-- --></A><H3>
LOCK</H3>
<PRE>
public static final char <B>LOCK</B></PRE>
<DL>
<DD>Use this constant with <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method to Lock User via Windows API.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#com.qotsa.controller.ShutDownController.LOCK">Constant Field Values</A></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="getInstance()"><!-- --></A><H3>
getInstance</H3>
<PRE>
public static <A HREF="../../../com/qotsa/controller/ShutDownController.html" title="class in com.qotsa.controller">ShutDownController</A> <B>getInstance</B>()</PRE>
<DL>
<DD>Use this method to get the unique instance of this class.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>ShutDownController Instance.</DL>
</DD>
</DL>
<HR>
<A NAME="shutDown(char, int, java.lang.String, int)"><!-- --></A><H3>
shutDown</H3>
<PRE>
public void <B>shutDown</B>(char mode,
int timeToShutDown,
java.lang.String message,
int timeRemainingToShowMessage)
throws java.io.IOException,
<A HREF="../../../com/qotsa/exception/InvalidParameter.html" title="class in com.qotsa.exception">InvalidParameter</A></PRE>
<DL>
<DD>Do a shut Down operation. If mode param is POWEROFF or RESTART and a previous call was made to this method with one of those mode, it calls a ABORT operation before continue.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>mode</CODE> - See Field Summary.<DD><CODE>timeToShutDown</CODE> - Use this param with POWEROFF or RESTART mode to indicate the time in seconds to perform the action (nothing but a countdown). If mode is not POWEROFF or RESTART this parameter is ignored.<DD><CODE>message</CODE> - Message to show to the user when mode is POWEROFF or RESTART. If mode is not POWEROFF or RESTART this parameter is ignored.<DD><CODE>timeRemainingToShowMessage</CODE> - Use this param with POWEROFF or RESTART mode to indicate the time in seconds to begin to show message to the user. If mode is not POWEROFF or RESTART this parameter is ignored.
<DT><B>Throws:</B>
<DD><CODE>java.io.IOException</CODE> - if an I/O error occurs.
<DD><CODE><A HREF="../../../com/qotsa/exception/InvalidParameter.html" title="class in com.qotsa.exception">InvalidParameter</A></CODE> - if timeToShutDown or timeRemainingToShowMessage is negative, if message parameter length is greater than 127 or if mode param is not one of those in Field Summary.</DL>
</DD>
</DL>
<HR>
<A NAME="shutDown(char)"><!-- --></A><H3>
shutDown</H3>
<PRE>
public void <B>shutDown</B>(char mode)
throws java.io.IOException,
<A HREF="../../../com/qotsa/exception/InvalidParameter.html" title="class in com.qotsa.exception">InvalidParameter</A></PRE>
<DL>
<DD>Do a Shut Down Operation. If use this with POWEROFF or RESTART mode the action is performed just at the moment you call this method. It磗 the same to call shutDown(ShutDownController.POWEROFF, 0, "",0) for example.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>mode</CODE> - See Field Summary.
<DT><B>Throws:</B>
<DD><CODE>java.io.IOException</CODE> - if an I/O error occurs.
<DD><CODE>If</CODE> - mode param is not one of those in Field Summary.
<DD><CODE><A HREF="../../../com/qotsa/exception/InvalidParameter.html" title="class in com.qotsa.exception">InvalidParameter</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getMode()"><!-- --></A><H3>
getMode</H3>
<PRE>
public char <B>getMode</B>()</PRE>
<DL>
<DD>Get the current Shut Down mode. You cannot set a mode. Call <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method again to change mode.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>Current Shut Down mode. If a invalid Parameter is throw at <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method then it will return ABORT.</DL>
</DD>
</DL>
<HR>
<A NAME="getTimeToShutDown()"><!-- --></A><H3>
getTimeToShutDown</H3>
<PRE>
public int <B>getTimeToShutDown</B>()</PRE>
<DL>
<DD>Get Current Time To Shut Down. You cannot set a Time To Shut Down. Call <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method again to change it.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>Current Time To Shut Down (Count Down).</DL>
</DD>
</DL>
<HR>
<A NAME="getTimeRemainingToShowMessage()"><!-- --></A><H3>
getTimeRemainingToShowMessage</H3>
<PRE>
public int <B>getTimeRemainingToShowMessage</B>()</PRE>
<DL>
<DD>Get the value of Time Remaining to Show Message (setted in timeRemainingToShowMessage param at <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method). You cannot set a Time Remaining To Show Message. Call <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method again to change it.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>Value of Time Remaining to Show Message.</DL>
</DD>
</DL>
<HR>
<A NAME="getMessage()"><!-- --></A><H3>
getMessage</H3>
<PRE>
public java.lang.String <B>getMessage</B>()</PRE>
<DL>
<DD>Get the message param setted at <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method. You cannot set a message. Call <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method again to change it.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>message setted at <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char, int, java.lang.String, int)"><CODE>shutDown(char mode, int timeToShutDown, String message, int timeRemainingToShowMessage)</CODE></A> or <A HREF="../../../com/qotsa/controller/ShutDownController.html#shutDown(char)"><CODE>shutDown(char mode)</CODE></A> method.</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ShutDownController.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
PREV CLASS
NEXT CLASS</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html?com/qotsa/controller/ShutDownController.html" target="_top"><B>FRAMES</B></A>
<A HREF="ShutDownController.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
</BODY>
</HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -