|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.SecurePlay.Comms.SPAbstractCommsClass
This is the SuperClass for comms services classes.
![]() |
![]() |
![]() |
![]() |
| Field Summary | |
java.lang.String |
commstype
Type of Comms Service |
| Constructor Summary | |
SPAbstractCommsClass()
Default Construtor |
|
| Method Summary | |
boolean |
addGame(java.lang.String gid,
SPCommsManagerCommsInterface gamcomobj)
This method adds an internal game to a specific comms service. |
boolean |
addPlayer(java.lang.String pid,
java.lang.String gid)
This method adds a player ID of a remote player serviced by this comm service. |
boolean |
APIactivate()
OPTIONAL - This is a shell method to trigger the activation of a comms service, if necessary. |
boolean |
APIconfigureCommService()
This method configures a comm service instance. |
boolean |
APIdeactivate()
OPTIONAL - This shell method is used to deactivate a comms service once it is no longer needed. |
java.lang.String |
getCommsID()
Getter function that returns the property: commsID |
java.lang.String |
getCommsServiceType()
This method returns a unique identifier for the type of comms service instance. |
SPMap |
getGameplayerList()
Getter function that returns the property: gameplayerList |
java.lang.String[] |
getInternalGameIDList()
Getter function that returns the property: internalGameIDList |
SPMap |
getPrinternalGameList()
Getter function that returns the property: printernalGameList |
boolean |
isGameInternal(java.lang.String gid)
This method returns whether a game is handled internally by a comms service |
void |
logError()
This is a shell for future error log. |
void |
processincoming(SPMessageClass inmess)
This method processes the incoming message. |
protected boolean |
prreceive(java.lang.String message)
This standard method handles incoming serialized messages that have been separated out of incoming data streams by the incoming method. |
protected boolean |
prsend(java.lang.String message)
This is a shell method for the actual transmission of a serialized message over a network using a specific communications transport. |
boolean |
removeGame(java.lang.String gid)
This method removes the association of a game with the comms service. |
boolean |
removePlayer(java.lang.String pid,
java.lang.String gid)
This method removes a player from the list of remote players served by this comm service. |
int |
sendMessage(SPMessageClass clearmessage,
SPMessageClass alternatemessage)
This method returns a number based on the input array to indicate how many of the input array's player IDs are included in the comms service playerIDList (This method takes the message and sends it over the network, if they are served by this comms service.) |
int |
sendMessage(java.lang.String[] receivers,
SPMessageClass clearmessage,
SPMessageClass alternatemessage)
This method returns a number based on the input array to indicate how many of the input array's player IDs are included in the comms service playerIDList This method is depreceated and will be removed in a future version of the software (This method takes the message and sends it over the network, if they are served by this comms service.) |
boolean |
setcommsID(java.lang.String cid)
This method sets the internal ID for a comms service if it has not been set. |
protected SPMessageClass[] |
SPdeserialize(java.lang.String message)
This method takes a serialized messagestring and turns it into an instance of the SPMessageClass |
protected java.lang.String |
SPserialize(SPMessageClass message)
This method takes an instance of the SPMessageClass and serializes it into a string. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public final java.lang.String commstype
| Constructor Detail |
public SPAbstractCommsClass()
| Method Detail |
public boolean setcommsID(java.lang.String cid)
SPAbstractCommsInterface
setcommsID in interface SPAbstractCommsInterfacecid - String - comms id
public java.lang.String getCommsServiceType()
getCommsServiceType in interface SPAbstractCommsInterface
public boolean addGame(java.lang.String gid,
SPCommsManagerCommsInterface gamcomobj)
SPAbstractCommsInterface
addGame in interface SPAbstractCommsInterfacegid - String - game idgamcomobj - SPCommsManagerCommsInterface - the comms object to be added to a game
public boolean removeGame(java.lang.String gid)
SPAbstractCommsInterface
removeGame in interface SPAbstractCommsInterfacegid - String - game id
public boolean APIconfigureCommService()
public boolean addPlayer(java.lang.String pid,
java.lang.String gid)
SPAbstractCommsInterface
addPlayer in interface SPAbstractCommsInterfacepid - String - player id to be addedgid - String - game id for the player to be added
public boolean removePlayer(java.lang.String pid,
java.lang.String gid)
SPAbstractCommsInterface
removePlayer in interface SPAbstractCommsInterfacepid - String - player id to ber removed.gid - String - game id from which the player is to be removed.
protected boolean prsend(java.lang.String message)
message - String - the message to be sent
protected boolean prreceive(java.lang.String message)
message - String - the incoming message
public int sendMessage(SPMessageClass clearmessage,
SPMessageClass alternatemessage)
SPAbstractCommsInterface
sendMessage in interface SPAbstractCommsInterfaceclearmessage - SPMessageClass - message for receiversalternatemessage - SPMessageClass - message or other game players
public int sendMessage(java.lang.String[] receivers,
SPMessageClass clearmessage,
SPMessageClass alternatemessage)
SPAbstractCommsInterface
sendMessage in interface SPAbstractCommsInterfacereceivers - String[] - array of playerIDsclearmessage - SPMessageClass - message for receiversalternatemessage - SPMessageClass - message or other game players
public boolean APIactivate()
public boolean APIdeactivate()
public void logError()
public java.lang.String getCommsID()
getCommsID in interface SPAbstractCommsInterfaceprotected java.lang.String SPserialize(SPMessageClass message)
message - SPMessageClass - a message to be seriealized into a string
protected SPMessageClass[] SPdeserialize(java.lang.String message)
message - String - serialized message object
public SPMap getGameplayerList()
getGameplayerList in interface SPAbstractCommsInterfacepublic java.lang.String[] getInternalGameIDList()
getInternalGameIDList in interface SPAbstractCommsInterfacepublic SPMap getPrinternalGameList()
getPrinternalGameList in interface SPAbstractCommsInterfacepublic boolean isGameInternal(java.lang.String gid)
SPAbstractCommsInterface
isGameInternal in interface SPAbstractCommsInterfacegid - - String
public void processincoming(SPMessageClass inmess)
inmess - SPMessageClass - the incoming message
void
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||