|
SMSLib 3.5.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.smslib.smsserver.interfaces.Interface<java.lang.Integer>
org.smslib.smsserver.interfaces.Database
public class Database
Interface for database communication with SMSServer.
Inbound messages and calls are logged in special tables, outbound messages
are retrieved from another table.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.smslib.smsserver.interfaces.Interface |
---|
Interface.InterfaceTypes |
Constructor Summary | |
---|---|
Database(java.lang.String myInterfaceId,
java.util.Properties myProps,
SMSServer myServer,
Interface.InterfaceTypes myType)
|
Method Summary | |
---|---|
void |
callReceived(java.lang.String gtwId,
java.lang.String callerId)
This method is called by SMSServer every time an inbound call is received. |
java.util.Collection<OutboundMessage> |
getMessagesToSend()
SMSServer calls this method in order to query the interface for messages that need to be send out. |
int |
getPendingMessagesToSend()
This method returns the number of outbound queued messages identified by this interface. |
void |
markMessage(OutboundMessage msg)
After a successful or unsuccessful attempt to send a message, SMSServer calls this method. |
void |
messagesReceived(java.util.Collection<InboundMessage> msgList)
This method is called by SMSServer every time a message (or more messages) is received. |
void |
start()
Called once before SMSServer starts its operation. |
void |
stop()
Called once after SMSServer has finished. |
Methods inherited from class org.smslib.smsserver.interfaces.Interface |
---|
getDescription, getId, getMessageCache, getProperty, getProperty, getServer, getType, isInbound, isOutbound, markMessages, setDescription |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Database(java.lang.String myInterfaceId, java.util.Properties myProps, SMSServer myServer, Interface.InterfaceTypes myType)
Method Detail |
---|
public void start() throws java.lang.Exception
Interface
Override this call if you wish to implement your own functionality.
start
in class Interface<java.lang.Integer>
java.lang.Exception
- An exception thrown will stop SMSServer from starting its
processing.public void stop() throws java.lang.Exception
Interface
Override this call if you wish to implement your own functionality.
stop
in class Interface<java.lang.Integer>
java.lang.Exception
public void callReceived(java.lang.String gtwId, java.lang.String callerId) throws java.lang.Exception
Interface
Override this call if you wish to implement your own functionality.
callReceived
in class Interface<java.lang.Integer>
gtwId
- The Id of the gateway which received the call.callerId
- The caller id.
java.lang.Exception
public void messagesReceived(java.util.Collection<InboundMessage> msgList) throws java.lang.Exception
Interface
Override this call if you wish to implement your own functionality.
messagesReceived
in class Interface<java.lang.Integer>
msgList
- A message list of all received messages.
java.lang.Exception
public java.util.Collection<OutboundMessage> getMessagesToSend() throws java.lang.Exception
Interface
Override this call if you wish to implement your own functionality.
getMessagesToSend
in class Interface<java.lang.Integer>
java.lang.Exception
public int getPendingMessagesToSend() throws java.lang.Exception
Interface
getPendingMessagesToSend
in class Interface<java.lang.Integer>
java.lang.Exception
public void markMessage(OutboundMessage msg) throws java.lang.Exception
Interface
Override this call if you wish to implement your own functionality.
markMessage
in class Interface<java.lang.Integer>
msg
- The Outbound message.
java.lang.Exception
|
SMSLib 3.5.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |