blueme.messenger.common
Class Server

java.lang.Object
  extended by blueme.messenger.common.Server
All Implemented Interfaces:
iConstants

public class Server
extends java.lang.Object
implements iConstants

Most functions that involve communication with the server, is placed here..


Field Summary
 
Fields inherited from interface blueme.messenger.common.iConstants
ADMIN_UID, APP_TITLE, BLUETOOTH_INDEX, BLUETOOTH_LENGTH, BLUETOOTH_POSTFIX, BLUETOOTH_PREFIX, COM_OBJECTS, DISCOVERY_SLEEP, GPRS_INDEX, MAX_REDIRECTS, MSG_MAX_COUNT, MSG_MAX_LENGTH, NICK_MAX_LENGTH, PID_LENGTH, SMS_PUSH_PORT, UID_LENGTH
 
Constructor Summary
Server()
           
 
Method Summary
static boolean addUser(iUserList user)
          Add a local user to the userlist saved on the server
static boolean deleteUser(iUserList user)
          Delete a user on the userlist saved on the server
static iUserList[] downloadUserList()
          This method gets the entire userlist save on the server.
static iUserList lookupBluetoothAddress(java.lang.String bluetoothAddress)
          Get userinfo based on a bluetooth address
static iUserList lookupPhoneNumber(java.lang.String phoneNumber)
          Get userinfo based on a phone number
static iUserList lookupUid(java.lang.String uid)
          Get userinfo based on a user ID
static iUserData registerUser(iUserData userData)
          Register this applications user/owner..
static void setDID(java.lang.String myDID)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Server

public Server()
Method Detail

setDID

public static void setDID(java.lang.String myDID)

lookupPhoneNumber

public static iUserList lookupPhoneNumber(java.lang.String phoneNumber)
                                   throws java.lang.InterruptedException
Get userinfo based on a phone number

Throws:
java.lang.InterruptedException

lookupBluetoothAddress

public static iUserList lookupBluetoothAddress(java.lang.String bluetoothAddress)
                                        throws java.lang.InterruptedException
Get userinfo based on a bluetooth address

Throws:
java.lang.InterruptedException

lookupUid

public static iUserList lookupUid(java.lang.String uid)
                           throws java.lang.InterruptedException
Get userinfo based on a user ID

Throws:
java.lang.InterruptedException

registerUser

public static iUserData registerUser(iUserData userData)
                              throws java.lang.InterruptedException
Register this applications user/owner..

Throws:
java.lang.InterruptedException

addUser

public static boolean addUser(iUserList user)
Add a local user to the userlist saved on the server


deleteUser

public static boolean deleteUser(iUserList user)
Delete a user on the userlist saved on the server


downloadUserList

public static iUserList[] downloadUserList()
                                    throws java.lang.InterruptedException
This method gets the entire userlist save on the server. It returns "null" if the userlist is empty, and throws an InterruptedException if the was some sort of connection problems.

Throws:
java.lang.InterruptedException