Implementation - Siemens XT65 User Manual

Siemens cell phone accessories user manual
Hide thumbs Also See for XT65:
Table of Contents

Advertisement

Java User's Guide
13.1 Using the AT Command API
122
13.1.3.2

Implementation

class ATListenerA implements ATCommandListener {
public void ATEvent(String Event) {
if (Event.indexOf("+CALA: Reminder 1") >= 0) {
/* take desired action after receiving the reminder */
} else if (Event.indexOf("+CALA: Reminder 2") >= 0) {
/* take desired action after receiving the reminder */
} else if (Event.indexOf("+CALA: Reminder 3") >= 0) {
/* take desired action after receiving the reminder */
}
/* No action taken for these events */
public void RINGChanged(boolean SignalState) {}
public void DCDChanged(boolean SignalState) {}
public void DSRChanged(boolean SignalState) {}
}
class ATListenerB implements ATCommandListener {
public void ATEvent(String Event) {
if (Event.indexOf("+SCKS: 0") >= 0) {
System.out.println("SIM Card is not inserted.");
/* perform other actions */
} else if (Event.indexOf("+SCKS: 1") >= 0) {
System.out.println("SIM Card is inserted.");
/* perform other actions */
}
}
public void RINGChanged(boolean SignalState) {
/* take some action when the RING signal changes if you want to */
}
public void DCDChanged(boolean SignalState) {
/* take some action when the DCD signal changes if you want to */
}
public void DSRChanged(boolean SignalState {}
/* take some action when the DSR signal changes if you want to */
}
public void CONNChanged(boolean SignalState {}
/* take some action when the state of a connection changes if you want
to */
}
}
wm_java_usersguide_v12
Confidential / Released
Page 119 of 123
s
2008-02-25

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Ac65Ac75Xt75Tc65

Table of Contents