📄 cservice.html
字号:
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#initialize()">initialize</A></B>()</CODE>
<BR>
Initializes the service.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#isIncomingMessage(java.lang.String)">isIncomingMessage</A></B>(java.lang.String pdu)</CODE>
<BR>
Checks if the message is SMS-DELIVER.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#isStatusReportMessage(java.lang.String)">isStatusReportMessage</A></B>(java.lang.String pdu)</CODE>
<BR>
Checks if the message is SMS-STATUS-REPORT.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#main(java.lang.String[])">main</A></B>(java.lang.String[] args)</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#readMessages(java.util.LinkedList, int)">readMessages</A></B>(java.util.LinkedList messageList,
int messageClass)</CODE>
<BR>
Reads SMS from the GSM device's memory.</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/jsmsengine/CService.html#received(org.jsmsengine.CIncomingMessage)">received</A></B>(<A HREF="../../org/jsmsengine/CIncomingMessage.html" title="class in org.jsmsengine">CIncomingMessage</A> message)</CODE>
<BR>
Virtual method, called upon receipt of a message (Asynchronous mode only!)</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#refreshDeviceInfo()">refreshDeviceInfo</A></B>()</CODE>
<BR>
Refreshes the GSM device specific information.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#sendMessage(org.jsmsengine.COutgoingMessage)">sendMessage</A></B>(<A HREF="../../org/jsmsengine/COutgoingMessage.html" title="class in org.jsmsengine">COutgoingMessage</A> message)</CODE>
<BR>
Send an SMS message from the GSM device.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#sendMessage(java.util.LinkedList)">sendMessage</A></B>(java.util.LinkedList messageList)</CODE>
<BR>
Send an series of SMS messages from the GSM device.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#setCacheDir(java.lang.String)">setCacheDir</A></B>(java.lang.String dir)</CODE>
<BR>
Sets the cache directory for messages.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#setConnected(boolean)">setConnected</A></B>(boolean connected)</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#setInitialized(boolean)">setInitialized</A></B>(boolean initialized)</CODE>
<BR>
</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/jsmsengine/CService.html#setOperationMode(int)">setOperationMode</A></B>(int mode)</CODE>
<BR>
Sets the operation mode of the GSM device</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#setPhoneBook(java.lang.String)">setPhoneBook</A></B>(java.lang.String phoneBookFile)</CODE>
<BR>
Loads the phonebook.</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/jsmsengine/CService.html#setReceiveMode(int)">setReceiveMode</A></B>(int receiveMode)</CODE>
<BR>
Sets the reception 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="../../org/jsmsengine/CService.html#setSimPin(java.lang.String)">setSimPin</A></B>(java.lang.String simPin)</CODE>
<BR>
Sets the SIM pin number.</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/jsmsengine/CService.html#setSmscNumber(java.lang.String)">setSmscNumber</A></B>(java.lang.String smscNumber)</CODE>
<BR>
Sets the Short Message Service Center (SMSC) number.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private java.util.LinkedList</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../org/jsmsengine/CService.html#splitLargeMessages(java.util.LinkedList)">splitLargeMessages</A></B>(java.util.LinkedList messageList)</CODE>
<BR>
</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.Object</B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_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>Field Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="_name"><!-- --></A><H3>
_name</H3>
<PRE>
public static final java.lang.String <B>_name</B></PRE>
<DL>
<DD>Internal Software Name.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService._name">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="_version"><!-- --></A><H3>
_version</H3>
<PRE>
public static final java.lang.String <B>_version</B></PRE>
<DL>
<DD>Version.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService._version">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="_reldate"><!-- --></A><H3>
_reldate</H3>
<PRE>
public static final java.lang.String <B>_reldate</B></PRE>
<DL>
<DD>Release Date.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService._reldate">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="log"><!-- --></A><H3>
log</H3>
<PRE>
private static java.util.logging.Logger <B>log</B></PRE>
<DL>
<DD>Logging facilities.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="ERR_OK"><!-- --></A><H3>
ERR_OK</H3>
<PRE>
public static final int <B>ERR_OK</B></PRE>
<DL>
<DD>This error value is returned when the operation was succesfull.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_OK">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_GENERIC_ERROR"><!-- --></A><H3>
ERR_GENERIC_ERROR</H3>
<PRE>
public static final int <B>ERR_GENERIC_ERROR</B></PRE>
<DL>
<DD>This is a generic error, which is not classified yet. More error classifications may be introduced at a later stage.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_GENERIC_ERROR">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_NOT_INITIALIZED"><!-- --></A><H3>
ERR_NOT_INITIALIZED</H3>
<PRE>
public static final int <B>ERR_NOT_INITIALIZED</B></PRE>
<DL>
<DD>This error value is returned when the service is not initialized yet. You should call method initialize().
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_NOT_INITIALIZED">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_NOT_CONNECTED"><!-- --></A><H3>
ERR_NOT_CONNECTED</H3>
<PRE>
public static final int <B>ERR_NOT_CONNECTED</B></PRE>
<DL>
<DD>This error value is returned when the service is not connected to the GSM device. You should call method connect().
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_NOT_CONNECTED">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_COMM_NOT_SUPPORTED"><!-- --></A><H3>
ERR_COMM_NOT_SUPPORTED</H3>
<PRE>
public static final int <B>ERR_COMM_NOT_SUPPORTED</B></PRE>
<DL>
<DD>This error value is returned when the GSM device does not support ASCII or PDU mode. This is a fatal error, in the sense that jSMSEngine can work only with GSM devices supporting ASCII or PDU Mode.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_COMM_NOT_SUPPORTED">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_CHARSET_HEX_NOT_SUPPORTED"><!-- --></A><H3>
ERR_CHARSET_HEX_NOT_SUPPORTED</H3>
<PRE>
public static final int <B>ERR_CHARSET_HEX_NOT_SUPPORTED</B></PRE>
<DL>
<DD>This error value is returned when the GSM device does not support HEX mode. This is a fatal error, in the sense that jSMSEngine can work only with GSM devices supporting HEX Mode when in ASCII mode. In order to get around this error, switch to PDU mode.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_CHARSET_HEX_NOT_SUPPORTED">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_CANNOT_DISABLE_INDICATIONS"><!-- --></A><H3>
ERR_CANNOT_DISABLE_INDICATIONS</H3>
<PRE>
public static final int <B>ERR_CANNOT_DISABLE_INDICATIONS</B></PRE>
<DL>
<DD>This error value is returned when the GSM device does not support the AT+CNMI command for disabling indications to TE.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_CANNOT_DISABLE_INDICATIONS">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_MESSAGE_NOT_FOUND"><!-- --></A><H3>
ERR_MESSAGE_NOT_FOUND</H3>
<PRE>
public static final int <B>ERR_MESSAGE_NOT_FOUND</B></PRE>
<DL>
<DD>This error value is returned when the specific message was not found. Double-check your message and/or memory index used.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_MESSAGE_NOT_FOUND">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="ERR_SEND_FAILED"><!-- --></A><H3>
ERR_SEND_FAILED</H3>
<PRE>
public static final int <B>ERR_SEND_FAILED</B></PRE>
<DL>
<DD>This error value is returned when a send-message operation failed. This could be attributed to a number of reasons: Coverage problems, invalid recipient phone number, GSM device malfunction.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#org.jsmsengine.CService.ERR_SEND_FAILED">Constant Field Values</A></DL>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -