ubiMobileClient
Fri Jan 27 19:11:38 KST 2006
Root Package
Class Diagrams
diagram <default>
Subpackages
package images
package net
package ubiMobile
Class Diagrams
Class Diagram <default>
package: <default>
Package Nodes
images
net
ubiMobile
Package Node Detail
Package images
Package ubiMobile
Package net
Package images
Class Diagrams
diagram images
Class Diagrams
Class Diagram images
package: images
Package net
Class Diagrams
diagram net
Subpackages
package net.benhui
Class Diagrams
Class Diagram net
package: net
Package Nodes
benhui
Package Node Detail
Package net.benhui
Package net.benhui
Class Diagrams
diagram benhui
Subpackages
package net.benhui.btgallery
Class Diagrams
Class Diagram benhui
package: net.benhui
Package Nodes
btgallery
Package Node Detail
Package net.benhui.btgallery
Package net.benhui.btgallery
Class Diagrams
diagram btgallery
Subpackages
package net.benhui.btgallery.bluelet
package net.benhui.btgallery.spp_bt
Classes
class MessageUI
class Util
Class Diagrams
Class Diagram btgallery
package: net.benhui.btgallery
Package Nodes
bluelet
spp_bt
Class Nodes
MessageUI
Util
Package Node Detail
Package net.benhui.btgallery.spp_bt
Package net.benhui.btgallery.bluelet
Class Detail
Class MessageUI
package: net.benhui.btgallery
net.benhui.btgallery.MessageUI
public class MessageUI
Extends:
Canvas
A screen to display text string on screen.

Description: This is a canvas screen to display the current messages in
virtual chat room. Only the latest messages are displayed. If there are more
messages than those can fit into one screen, old messages are roll off from
the upper edge. User is not able to scroll back to see old messages, however,
the old messages is still available in msgs Vector until a clear command
is invoked. When a clear command is invoked, all message will be removed
from msgs vector.


Copyright: Copyright (c) 2003

Author:
Ben Hui (www.benhui.net)
Version:
1.0
Field Summary
public int
public int
Font
int
int
int
public Vector
int
int
int
Constructor Summary
public
Method Summary
public void
add(String s)
public void
addNoRepaint(String s)
public void
public void
keyPressed(int key)
protected void
paint(Graphics g)
Field Detail
backTo
public int backTo = 0

bookmarkId
public int bookmarkId = 1

f
Font f

fh
int fh

h
int h

midx
int midx = 0

msgs
public Vector msgs = new Vector()

w
int w

x0
int x0 = 0

y0
int y0 = 0
Constructor Detail
MessageUI
public MessageUI()
Method Detail
add
public void add(String s)

addNoRepaint
public void addNoRepaint(String s)

clear
public void clear()

keyPressed
public void keyPressed(int key)

paint
protected void paint(Graphics g)
Class Util
package: net.benhui.btgallery
public class Util

Title: A utility class to dump JABWT object contents and perform object conversion


Description: A collection of print utility method that output the attributes of JABWT objects to System.out
Supported objects are:

LocalDevice

RemoteDevice

DeviceClass

UUID

ServiceRecord

DataElement

Major Service Class

Major, Minor Device ClassAttribute ID

OBEXHeader (incomplete)


Copyright: Copyright (c) 2003

Author:
Ben Hui (www.benhui.net)
Version:
1.0

LICENSE:
This code is licensed under GPL. (See http://www.gnu.org/copyleft/gpl.html)
Constructor Summary
private
Method Summary
public static String
attrTypeToName(int type)
public static String
idToName(int id)
public static String
public static String
public static String
minorToName(int d, int m)
public static void
printDataElement(DataElement e, int id, String indent)
public static void
printLocalDevice(LocalDevice dev)
public static void
printObexHeaderSet(HeaderSet h)
public static void
printRemoteDevice(RemoteDevice dev, DeviceClass devClass)
public static void
printServiceRecord(ServiceRecord r)
public static String
toHexString(byte[] b)
public static String
public static String
toHexString(long l)
public static String
uuidToName(UUID u)
Constructor Detail
Util
private Util()
Method Detail
attrTypeToName
public static String attrTypeToName(int type)

idToName
public static String idToName(int id)

majorServiceToName
public static String majorServiceToName(int d)

majorToName
public static String majorToName(int d)

minorToName
public static String minorToName(int d, int m)
Parameters:
d major device class
m minor device class
Returns

printDataElement
public static void printDataElement(DataElement e, int id, String indent)

printLocalDevice
public static void printLocalDevice(LocalDevice dev)

printObexHeaderSet
public static void printObexHeaderSet(HeaderSet h)

printRemoteDevice
public static void printRemoteDevice(RemoteDevice dev, DeviceClass devClass)

printServiceRecord
public static void printServiceRecord(ServiceRecord r)

toHexString
public static String toHexString(long l)

toHexString
public static String toHexString(byte[] b)

toHexString
public static String toHexString(int i)

uuidToName
public static String uuidToName(UUID u)
Package net.benhui.btgallery.bluelet
Class Diagrams
diagram bluelet
Classes
class BLUElet
class RemoteDeviceUI
Class Diagrams
Class Diagram bluelet
package: net.benhui.btgallery.bluelet
Class Nodes
BLUElet
RemoteDeviceUI
Class Detail
Class BLUElet
package: net.benhui.btgallery.bluelet
public class BLUElet
Implements:
CommandListener

Title: Bluetooth Application Utility GUI Component


Description:

Note: This class must be used as singleton.

Author:
Ben Hui (www.benhui.net) - refered by Yoosoo Oh (2005.11.13)
Version:
1.0

LICENSE:
This code is licensed under GPL. (See http://www.gnu.org/copyleft/gpl.html)
Inner Class Summary
final static class
BLUElet.Listener
   Bluetooth listener object.
 
final static class
BLUElet.Worker
   Worker thread that invoke callback CommandListener upon Bluetooth event occurs.
 
Field Summary
private DiscoveryAgent
public static Command
public static CommandListener
public static Command
private LocalDevice
public static Vector
public int
public static Vector
public int
public static Display
public static MIDlet
private final static int
private final static int
private final static int
public static BLUElet
public boolean
public static Command
public static int
public int
public static Vector
public UUID[]
int
cmd
Constructor Summary
public
BLUElet(MIDlet host, CommandListener listener)
   Creae a new BLUElet.
 
public
Worker(int cmd)
Method Summary
public void
commandAction(Command c, Displayable d)
public void
destroyApp(boolean unconditional)
   Mirror MIDlet.destroyApp(), should be called by your MIDlet destroyApp().
 
public int
   Return the Bluetooth result code from device inquiry.
 
public ServiceRecord[]
   Get all discovered services from selected remote device.
 
public ServiceRecord
   Get the first discovered service from selected remote device.
 
public RemoteDevice
   Return user selected remote device that is used for service discovery.
 
public int
   Return the Bluetooth result code from service discovery.
 
public Screen
   Obtain reference to device selection screen component.
 
public void
deviceDiscovered(RemoteDevice remoteDevice, DeviceClass deviceClass)
public void
inquiryCompleted(int complete)
public void
servicesDiscovered(int transId, ServiceRecord[] records)
public void
serviceSearchCompleted(int transId, int complete)
public static void
log(String s)
   Utility function to write log message.
 
public void
   Mirror MIDlet.pauseApp(), should be called by your MIDlet pauseApp().
 
public void
public void
   Mirror MIDlet.startApp(), should be called by your MIDlet startApp().
 
public void
startInquiry(int mode, UUID[] serviceUUIDs)
   Start device inquiry.
 
public void
run()
Field Detail
agent
private DiscoveryAgent agent

BACK
public static Command BACK = new Command( "Back", Command.BACK, 1 )

callback
public static CommandListener callback

COMPLETED
public static Command COMPLETED = new Command( "COMPLETED", Command.SCREEN, 1 )

device
private LocalDevice device

deviceClasses
public static Vector deviceClasses = new Vector()

deviceReturnCode
public int deviceReturnCode

devices
public static Vector devices = new Vector()

discoveryMode
public int discoveryMode

display
public static Display display

host
public static MIDlet host

ID_DEVICE_COMPLETED
private final static int ID_DEVICE_COMPLETED = 2

ID_DEVICE_SELECTED
private final static int ID_DEVICE_SELECTED = 3

ID_SERVICE_COMPLETED
private final static int ID_SERVICE_COMPLETED = 1

instance
public static BLUElet instance

remotedeviceui
private RemoteDeviceUI remotedeviceui = null

search_loop_flag
public boolean search_loop_flag = true

SELECTED
public static Command SELECTED = new Command( "SELECTED", Command.SCREEN, 1 )

selectedDevice
public static int selectedDevice = -1

serviceReturnCode
public int serviceReturnCode

services
public static Vector services = new Vector()

serviceUUIDs
public UUID[] serviceUUIDs = null
Constructor Detail
BLUElet
public BLUElet(MIDlet host, CommandListener listener)
Creae a new BLUElet.
Parameters:
host MIDlet
listener CommandListener
Method Detail
commandAction
public void commandAction(Command c, Displayable d)
Parameters:
c Command
d Displayable

destroyApp
public void destroyApp(boolean unconditional)
Mirror MIDlet.destroyApp(), should be called by your MIDlet destroyApp().

getDeviceDiscoveryReturnCode
public int getDeviceDiscoveryReturnCode()
Return the Bluetooth result code from device inquiry.
This is the result code obtained in DiscoveryListener.inquiryCompleted().
Your application cal call this method after a COMPLETED callback event
is received.
Returns:
int

getDiscoveredServices
public ServiceRecord[] getDiscoveredServices()
Get all discovered services from selected remote device.
Your application call this method after your app receive COMPLETED callback
event. This will return all services that match your UUIDs in startInquiry().
Returns:
ServiceRecord[]

getFirstDiscoveredService
public ServiceRecord getFirstDiscoveredService()
Get the first discovered service from selected remote device.
Your application call this method after your app receives COMPLETED
callback event. This will return the first service that match your
UUIDs in startInquiry().
Returns:
ServiceRecord null if no service discovered

getSelectedDevice
public RemoteDevice getSelectedDevice()
Return user selected remote device that is used for service discovery.
Your application can call this after your app received SELECTED callback
event.
Returns:
RemoteDevice null if user didn't select anything

getServiceDiscoveryReturnCode
public int getServiceDiscoveryReturnCode()
Return the Bluetooth result code from service discovery.
This is the result code obtained in DiscoveryListener.serviceSearchCompleted().
Your application cal call this method after a COMPLETED callback event
is received.
Returns:
int

getUI
public Screen getUI()
Obtain reference to device selection screen component.
You should show this screen when user invoke device search.
Returns:
Screen

log
public static void log(String s)
Utility function to write log message.
Parameters:
s String

pauseApp
public void pauseApp()
Mirror MIDlet.pauseApp(), should be called by your MIDlet pauseApp().

searchAction
public void searchAction()

startApp
public void startApp()
Mirror MIDlet.startApp(), should be called by your MIDlet startApp().

startInquiry
public void startInquiry(int mode, UUID[] serviceUUIDs)
Start device inquiry. Your application call this method to start inquiry.
Parameters:
mode int one of DiscoveryAgent.GIAC or DiscoveryAgent.LIAC
serviceUUIDs UUID[]
Class RemoteDeviceUI
package: net.benhui.btgallery.bluelet
net.benhui.btgallery.bluelet.RemoteDeviceUI
class RemoteDeviceUI
Extends:
List

Title: Remote Device List Component


Description: This is a List screen to display a list of discovered Bluetooth
devices. This is a class used by BLUEletUI.

Author:
Ben Hui (www.benhui.net)
Version:
1.0

LICENSE:
This code is licensed under GPL. (See http://www.gnu.org/copyleft/gpl.html)
Constructor Summary
public
Method Summary
public void
setMsg(String str)
   Set a one-line message to screen.
 
public void
   refresh the list with blutooth devices
 
Constructor Detail
RemoteDeviceUI
public RemoteDeviceUI()
Method Detail
setMsg
public void setMsg(String str)
Set a one-line message to screen.
Parameters:
str String

showui
public void showui()
refresh the list with blutooth devices
Package net.benhui.btgallery.spp_bt
Class Diagrams
diagram spp_bt
Classes
class SPP_Client
class SPP_Server
Class Diagrams
Class Diagram spp_bt
package: net.benhui.btgallery.spp_bt
Class Nodes
SPP_Client
SPP_Server
Class Detail
Class SPP_Client
package: net.benhui.btgallery.spp_bt
public class SPP_Client

Title: Example Serial Port Profile Client


Description: Important area: send_SPP_message()
This client only does the portion that send and receive data over a SPP
connection. In an actual client applicaion, you also need to do device
discovery and service discovery. This is taken care by Bluelet.
Author:
Ben Hui (www.benhui.net) - refered by Yoosoo Oh (2005.11.13)
Version:
1.0

LICENSE:
This code is licensed under GPL. (See http://www.gnu.org/copyleft/gpl.html)
Constructor Summary
public
Method Summary
public void
log(String s)
public void
send_SPP_message(ServiceRecord r, String msg)
   Send a message to server using Serial Port Profile.
 
Constructor Detail
SPP_Client
public SPP_Client()
Method Detail
log
public void log(String s)

send_SPP_message
public void send_SPP_message(ServiceRecord r, String msg)
Send a message to server using Serial Port Profile.
Connect to incoming service record, send a text, and read
in a text. This method illustrate how to send and receive
data using serial port profile.
Device and service discovery is part of Serial Port client but it is
done by Bluelet component. See SPP_MIDlet for usage of Bluelet.
Parameters:
msg
Class SPP_Server
package: net.benhui.btgallery.spp_bt
public class SPP_Server
Implements:
java.lang.Runnable

Title: Example Serial Port Profile Server.


Description: This example server only handle one SPP server connection
and wait for a client to connect. Once a client connection accept, it read
one string off the connection stream, display this string on screen, then
echo the string back to client.
Then it waits for the next client connection again.


Description: Important area: run()

Author:
Ben Hui (www.benhui.net) - refered by Yoosoo Oh (2005.11.13)
Version:
1.0

LICENSE:
This code is licensed under GPL. (See http://www.gnu.org/copyleft/gpl.html)
Field Summary
DiscoveryAgent
LocalDevice
public boolean
public StreamConnectionNotifier
private final static int
public final static UUID
Constructor Summary
public
Method Summary
public void
log(String s)
   An utility function to display a log message
 
public void
run()
public void
Field Detail
agent
DiscoveryAgent agent

device
LocalDevice device

done
public boolean done = false

server
public StreamConnectionNotifier server

SERVICE_TELEPHONY
private final static int SERVICE_TELEPHONY = 0x400000

uuid
public final static UUID uuid = new UUID("102030405060708090A0B0C0D0E0F010", false)
Constructor Detail
SPP_Server
public SPP_Server()
Method Detail
log
public void log(String s)
An utility function to display a log message
Parameters:
s String

run
public void run()

run_server
public void run_server()
Package ubiMobile
Class Diagrams
diagram ubiMobile
Classes
class RecStoreDB
class ubiMobile
Class Diagrams
Class Diagram ubiMobile
package: ubiMobile
Class Nodes
RecStoreDB
ubiMobile
Class Detail
Class RecStoreDB
package: ubiMobile
public class RecStoreDB
This class is ready to save the user's profile information in Record Store.

Since:
J2SDK1.5
Version:
ubi-UCAM 2.0 (ubiSensor)
Author:
Yoosoo Oh
Field Summary
private RecordStore
public String
public String
Constructor Summary
public
   Creates a new instance of RecStoreDB_ID
 
Method Summary
public void
   A method to close Record Store
 
public void
deleteRecord(int id)
   A method to delete data with specific record ID in Record Store
 
public void
   A method to open Record Store
 
public void
   A method to read data from Record Store
 
public void
writeRecord(String record_str)
   A method to write data into Record Store
 
Field Detail
recStore
private RecordStore recStore = null

REC_STORE
public String REC_STORE

returnData
public String returnData = null
Constructor Detail
RecStoreDB
public RecStoreDB()
Creates a new instance of RecStoreDB_ID
Method Detail
closeRecStore
public void closeRecStore()
A method to close Record Store

deleteRecord
public void deleteRecord(int id)
A method to delete data with specific record ID in Record Store

openRecStore
public void openRecStore()
A method to open Record Store

readRecords
public void readRecords()
A method to read data from Record Store

writeRecord
public void writeRecord(String record_str)
A method to write data into Record Store
Class ubiMobile
package: ubiMobile
ubiMobile.ubiMobile
public class ubiMobile
Extends:
MIDlet
Implements:
javax.microedition.lcdui.CommandListener
This class is ready to manage all classes of ubiMobile.

Since:
J2SDK1.5
Version:
ubi-UCAM 2.0 (ubiSensor)
Author:
Yoosoo Oh
Inner Class Summary
public final static class
ubiMobile.BTClientConnect
   A thread to send the first confirm message to the server through Bluetooth Communication
 
public final static class
ubiMobile.DataSend
   A thread to send a message to the server through Bluetooth Communication
 
Field Summary
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
   To utilize Bluelet to do device disvcovery and service discovery
 
public String
javax.microedition.lcdui.List
private Date
   To record store object
 
public static Display
javax.microedition.lcdui.ChoiceGroup
javax.microedition.lcdui.Command
javax.microedition.lcdui.Form
javax.microedition.lcdui.Form
javax.microedition.lcdui.Form
javax.microedition.lcdui.Form
javax.microedition.lcdui.Form
javax.microedition.lcdui.Form
javax.microedition.lcdui.Command
javax.microedition.lcdui.Gauge
javax.microedition.lcdui.StringItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.ImageItem
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
javax.microedition.lcdui.Image
public static ubiMobile
   To commonly used singleton object
 
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Gauge
javax.microedition.lcdui.StringItem
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.TextField
javax.microedition.lcdui.Command
javax.microedition.lcdui.ChoiceGroup
javax.microedition.lcdui.List
javax.microedition.lcdui.ChoiceGroup
javax.microedition.lcdui.Command
javax.microedition.lcdui.DateField
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
javax.microedition.lcdui.Command
String
   To send messages
 
   SPP client logic
 
javax.microedition.lcdui.StringItem
javax.microedition.lcdui.StringItem
javax.microedition.lcdui.TextField
javax.microedition.lcdui.TextField
javax.microedition.lcdui.TextField
javax.microedition.lcdui.TextField
Constructor Summary
public
   Creates a new instance of ubiMobile
 
Method Summary
public static void
alert(Exception e, Displayable next_screen)
   An utility function that show a alert box that display an exception message.
 
public static void
alert(String m, Displayable next_screen)
   An utility function that show a alert box that display a message.
 
public void
run()
public Displayable
   A method to call main form
 
public void
commandAction(javax.microedition.lcdui.Command command, javax.microedition.lcdui.Displayable displayable)
   Called by the system to indicate that a command has been invoked on a particular displayable.
 
public void
run()
public void
destroyApp(boolean unconditional)
private javax.microedition.lcdui.Command
   This method returns instance for backCommand_control component and should be called instead of accessing backCommand_control field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for backCommand_heating component and should be called instead of accessing backCommand_heating field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for backCommand_lighting component and should be called instead of accessing backCommand_lighting field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for backCommand_profile component and should be called instead of accessing backCommand_profile field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for backCommand_schedulelist component and should be called instead of accessing backCommand_schedulelist field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for backCommand_schedulesettting component and should be called instead of accessing backCommand_schedulesettting field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for backCommand_security component and should be called instead of accessing backCommand_security field directly.
 
private javax.microedition.lcdui.List
   This method returns instance for control_list component and should be called instead of accessing control_list field directly.
 
private javax.microedition.lcdui.ChoiceGroup
   This method returns instance for DoorLock component and should be called instead of accessing DoorLock field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for exitCommand_program component and should be called instead of accessing exitCommand_program field directly.
 
private javax.microedition.lcdui.Form
   This method returns instance for form_heating component and should be called instead of accessing form_heating field directly.
 
private javax.microedition.lcdui.Form
   This method returns instance for form_lighting component and should be called instead of accessing form_lighting field directly.
 
private javax.microedition.lcdui.Form
   This method returns instance for form_main component and should be called instead of accessing form_main field directly.
 
private javax.microedition.lcdui.Form
   This method returns instance for form_profile component and should be called instead of accessing form_profile field directly.
 
private javax.microedition.lcdui.Form
   This method returns instance for form_schedule component and should be called instead of accessing form_schedule field directly.
 
private javax.microedition.lcdui.Form
   This method returns instance for form_security component and should be called instead of accessing form_security field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for heating_execution component and should be called instead of accessing heating_execution field directly.
 
private javax.microedition.lcdui.Gauge
   This method returns instance for heating_level component and should be called instead of accessing heating_level field directly.
 
private javax.microedition.lcdui.StringItem
   This method returns instance for heating_value component and should be called instead of accessing heating_value field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem1 component and should be called instead of accessing imageItem1 field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem2 component and should be called instead of accessing imageItem2 field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem3 component and should be called instead of accessing imageItem3 field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem_heater component and should be called instead of accessing imageItem_heater field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem_light component and should be called instead of accessing imageItem_light field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem_main component and should be called instead of accessing imageItem_main field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem_profile_m component and should be called instead of accessing imageItem_profile_m field directly.
 
private javax.microedition.lcdui.ImageItem
   This method returns instance for imageItem_schedule component and should be called instead of accessing imageItem_schedule field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_door component and should be called instead of accessing image_door field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_door_s component and should be called instead of accessing image_door_s field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_heater component and should be called instead of accessing image_heater field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_heater_s component and should be called instead of accessing image_heater_s field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_light component and should be called instead of accessing image_light field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_light_s component and should be called instead of accessing image_light_s field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_profile_m component and should be called instead of accessing image_profile_m field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_profile_m_s component and should be called instead of accessing image_profile_m_s field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_profile_w component and should be called instead of accessing image_profile_w field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_profile_w_s component and should be called instead of accessing image_profile_w_s field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_schedule component and should be called instead of accessing image_schedule field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_schedule_s component and should be called instead of accessing image_schedule_s field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_ubiMobile component and should be called instead of accessing image_ubiMobile field directly.
 
private javax.microedition.lcdui.Image
   This method returns instance for image_ubimobile_s component and should be called instead of accessing image_ubimobile_s field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for itemCommand1 component and should be called instead of accessing itemCommand1 field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for lighting_execution component and should be called instead of accessing lighting_execution field directly.
 
private javax.microedition.lcdui.Gauge
   This method returns instance for lighting_level component and should be called instead of accessing lighting_level field directly.
 
private javax.microedition.lcdui.StringItem
   This method returns instance for lighting_value component and should be called instead of accessing lighting_value field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for profile_save component and should be called instead of accessing profile_save field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for schedule_delete component and should be called instead of accessing schedule_delete field directly.
 
private javax.microedition.lcdui.TextField
   This method returns instance for schedule_duration component and should be called instead of accessing schedule_duration field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for schedule_edit component and should be called instead of accessing schedule_edit field directly.
 
private javax.microedition.lcdui.ChoiceGroup
   This method returns instance for schedule_event component and should be called instead of accessing schedule_event field directly.
 
private javax.microedition.lcdui.List
   This method returns instance for schedule_list component and should be called instead of accessing schedule_list field directly.
 
private javax.microedition.lcdui.ChoiceGroup
   This method returns instance for schedule_place component and should be called instead of accessing schedule_place field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for schedule_save component and should be called instead of accessing schedule_save field directly.
 
private javax.microedition.lcdui.DateField
   This method returns instance for schedule_time component and should be called instead of accessing schedule_time field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for schedule_update component and should be called instead of accessing schedule_update field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for screenCommand_controllist component and should be called instead of accessing screenCommand_controllist field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for screenCommand_scheduler component and should be called instead of accessing screenCommand_scheduler field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for screenCommand_search component and should be called instead of accessing screenCommand_search field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for screenCommand_userprofile component and should be called instead of accessing screenCommand_userprofile field directly.
 
private javax.microedition.lcdui.Command
   This method returns instance for security_execution component and should be called instead of accessing security_execution field directly.
 
private javax.microedition.lcdui.StringItem
   This method returns instance for stringItem_profile_info component and should be called instead of accessing stringItem_profile_info field directly.
 
private javax.microedition.lcdui.StringItem
   This method returns instance for stringItem_time component and should be called instead of accessing stringItem_time field directly.
 
private javax.microedition.lcdui.TextField
   This method returns instance for textField1 component and should be called instead of accessing textField1 field directly.
 
private javax.microedition.lcdui.TextField
   This method returns instance for textField_email component and should be called instead of accessing textField_email field directly.
 
private javax.microedition.lcdui.TextField
   This method returns instance for textField_id component and should be called instead of accessing textField_id field directly.
 
private javax.microedition.lcdui.TextField
   This method returns instance for textField_password component and should be called instead of accessing textField_password field directly.
 
private void
   This method initializes UI of the application.
 
public static void
log(String s)
   An utility function to display a log message
 
public void
public void
   A method to load User Profile information from Record Store
 
public void
   A method to save User Profile information into Record Store
 
public void
   A method to display main form
 
public void
   A method to ready for Bluetooth & send the first confirm message
 
public void
Field Detail
backCommand_control
javax.microedition.lcdui.Command backCommand_control

backCommand_heating
javax.microedition.lcdui.Command backCommand_heating

backCommand_lighting
javax.microedition.lcdui.Command backCommand_lighting

backCommand_profile
javax.microedition.lcdui.Command backCommand_profile

backCommand_schedulelist
javax.microedition.lcdui.Command backCommand_schedulelist

backCommand_schedulesettting
javax.microedition.lcdui.Command backCommand_schedulesettting

backCommand_security
javax.microedition.lcdui.Command backCommand_security

bluelet
BLUElet bluelet = null
To utilize Bluelet to do device disvcovery and service discovery

Bluetooth_address
public String Bluetooth_address = null

control_list
javax.microedition.lcdui.List control_list

currentTime
private Date currentTime

DB_EMAIL
RecStoreDB DB_EMAIL = null

DB_ID
RecStoreDB DB_ID = null
To record store object

DB_PWD
RecStoreDB DB_PWD = null

DB_TIME
RecStoreDB DB_TIME = null

display
public static Display display

DoorLock
javax.microedition.lcdui.ChoiceGroup DoorLock

exitCommand_program
javax.microedition.lcdui.Command exitCommand_program

form_heating
javax.microedition.lcdui.Form form_heating

form_lighting
javax.microedition.lcdui.Form form_lighting

form_main
javax.microedition.lcdui.Form form_main

form_profile
javax.microedition.lcdui.Form form_profile

form_schedule
javax.microedition.lcdui.Form form_schedule

form_security
javax.microedition.lcdui.Form form_security

heating_execution
javax.microedition.lcdui.Command heating_execution

heating_level
javax.microedition.lcdui.Gauge heating_level

heating_value
javax.microedition.lcdui.StringItem heating_value

imageItem1
javax.microedition.lcdui.ImageItem imageItem1

imageItem2
javax.microedition.lcdui.ImageItem imageItem2

imageItem3
javax.microedition.lcdui.ImageItem imageItem3

imageItem_door
javax.microedition.lcdui.ImageItem imageItem_door

imageItem_heater
javax.microedition.lcdui.ImageItem imageItem_heater

imageItem_light
javax.microedition.lcdui.ImageItem imageItem_light

imageItem_main
javax.microedition.lcdui.ImageItem imageItem_main

imageItem_profile_m
javax.microedition.lcdui.ImageItem imageItem_profile_m

imageItem_schedule
javax.microedition.lcdui.ImageItem imageItem_schedule

image_door
javax.microedition.lcdui.Image image_door

image_door_s
javax.microedition.lcdui.Image image_door_s

image_heater
javax.microedition.lcdui.Image image_heater

image_heater_s
javax.microedition.lcdui.Image image_heater_s

image_light
javax.microedition.lcdui.Image image_light

image_light_s
javax.microedition.lcdui.Image image_light_s

image_profile_m
javax.microedition.lcdui.Image image_profile_m

image_profile_m_s
javax.microedition.lcdui.Image image_profile_m_s

image_profile_w
javax.microedition.lcdui.Image image_profile_w

image_profile_w_s
javax.microedition.lcdui.Image image_profile_w_s

image_schedule
javax.microedition.lcdui.Image image_schedule

image_schedule_s
javax.microedition.lcdui.Image image_schedule_s

image_ubiMobile
javax.microedition.lcdui.Image image_ubiMobile

image_ubimobile_s
javax.microedition.lcdui.Image image_ubimobile_s

instance
public static ubiMobile instance
To commonly used singleton object

itemCommand1
javax.microedition.lcdui.Command itemCommand1

lighting_execution
javax.microedition.lcdui.Command lighting_execution

lighting_level
javax.microedition.lcdui.Gauge lighting_level

lighting_value
javax.microedition.lcdui.StringItem lighting_value

profile_save
javax.microedition.lcdui.Command profile_save

schedule_delete
javax.microedition.lcdui.Command schedule_delete

schedule_duration
javax.microedition.lcdui.TextField schedule_duration

schedule_edit
javax.microedition.lcdui.Command schedule_edit

schedule_event
javax.microedition.lcdui.ChoiceGroup schedule_event

schedule_list
javax.microedition.lcdui.List schedule_list

schedule_place
javax.microedition.lcdui.ChoiceGroup schedule_place

schedule_save
javax.microedition.lcdui.Command schedule_save

schedule_time
javax.microedition.lcdui.DateField schedule_time

schedule_update
javax.microedition.lcdui.Command schedule_update

screenCommand_controllist
javax.microedition.lcdui.Command screenCommand_controllist

screenCommand_scheduler
javax.microedition.lcdui.Command screenCommand_scheduler

screenCommand_search
javax.microedition.lcdui.Command screenCommand_search

screenCommand_userprofile
javax.microedition.lcdui.Command screenCommand_userprofile

security_execution
javax.microedition.lcdui.Command security_execution

sndMessage
String sndMessage = null
To send messages

spp_client
SPP_Client spp_client = null
SPP client logic

stringItem_profile_info
javax.microedition.lcdui.StringItem stringItem_profile_info

stringItem_time
javax.microedition.lcdui.StringItem stringItem_time

textField1
javax.microedition.lcdui.TextField textField1

textField_email
javax.microedition.lcdui.TextField textField_email

textField_id
javax.microedition.lcdui.TextField textField_id

textField_password
javax.microedition.lcdui.TextField textField_password
Constructor Detail
ubiMobile
public ubiMobile()
Creates a new instance of ubiMobile
Method Detail
alert
public static void alert(Exception e, Displayable next_screen)
An utility function that show a alert box that display an exception message.
Parameters:
e
next_screen

alert
public static void alert(String m, Displayable next_screen)
An utility function that show a alert box that display a message.
Parameters:
m String
next_screen Screen

call_form_main
public Displayable call_form_main()
A method to call main form

commandAction
public void commandAction(javax.microedition.lcdui.Command command, javax.microedition.lcdui.Displayable displayable)
Called by the system to indicate that a command has been invoked on a particular displayable.
Parameters:
command the Command that ws invoked
displayable the Displayable on which the command was invoked

destroyApp
public void destroyApp(boolean unconditional)

get_backCommand_control
private javax.microedition.lcdui.Command get_backCommand_control()
This method returns instance for backCommand_control component and should be called instead of accessing backCommand_control field directly.
Returns:
Instance for backCommand_control component

get_backCommand_heating
private javax.microedition.lcdui.Command get_backCommand_heating()
This method returns instance for backCommand_heating component and should be called instead of accessing backCommand_heating field directly.
Returns:
Instance for backCommand_heating component

get_backCommand_lighting
private javax.microedition.lcdui.Command get_backCommand_lighting()
This method returns instance for backCommand_lighting component and should be called instead of accessing backCommand_lighting field directly.
Returns:
Instance for backCommand_lighting component

get_backCommand_profile
private javax.microedition.lcdui.Command get_backCommand_profile()
This method returns instance for backCommand_profile component and should be called instead of accessing backCommand_profile field directly.
Returns:
Instance for backCommand_profile component

get_backCommand_schedulelist
private javax.microedition.lcdui.Command get_backCommand_schedulelist()
This method returns instance for backCommand_schedulelist component and should be called instead of accessing backCommand_schedulelist field directly.
Returns:
Instance for backCommand_schedulelist component

get_backCommand_schedulesettting
private javax.microedition.lcdui.Command get_backCommand_schedulesettting()
This method returns instance for backCommand_schedulesettting component and should be called instead of accessing backCommand_schedulesettting field directly.
Returns:
Instance for backCommand_schedulesettting component

get_backCommand_security
private javax.microedition.lcdui.Command get_backCommand_security()
This method returns instance for backCommand_security component and should be called instead of accessing backCommand_security field directly.
Returns:
Instance for backCommand_security component

get_control_list
private javax.microedition.lcdui.List get_control_list()
This method returns instance for control_list component and should be called instead of accessing control_list field directly.
Returns:
Instance for control_list component

get_DoorLock
private javax.microedition.lcdui.ChoiceGroup get_DoorLock()
This method returns instance for DoorLock component and should be called instead of accessing DoorLock field directly.
Returns:
Instance for DoorLock component

get_exitCommand_program
private javax.microedition.lcdui.Command get_exitCommand_program()
This method returns instance for exitCommand_program component and should be called instead of accessing exitCommand_program field directly.
Returns:
Instance for exitCommand_program component

get_form_heating
private javax.microedition.lcdui.Form get_form_heating()
This method returns instance for form_heating component and should be called instead of accessing form_heating field directly.
Returns:
Instance for form_heating component

get_form_lighting
private javax.microedition.lcdui.Form get_form_lighting()
This method returns instance for form_lighting component and should be called instead of accessing form_lighting field directly.
Returns:
Instance for form_lighting component

get_form_main
private javax.microedition.lcdui.Form get_form_main()
This method returns instance for form_main component and should be called instead of accessing form_main field directly.
Returns:
Instance for form_main component

get_form_profile
private javax.microedition.lcdui.Form get_form_profile()
This method returns instance for form_profile component and should be called instead of accessing form_profile field directly.
Returns:
Instance for form_profile component

get_form_schedule
private javax.microedition.lcdui.Form get_form_schedule()
This method returns instance for form_schedule component and should be called instead of accessing form_schedule field directly.
Returns:
Instance for form_schedule component

get_form_security
private javax.microedition.lcdui.Form get_form_security()
This method returns instance for form_security component and should be called instead of accessing form_security field directly.
Returns:
Instance for form_security component

get_heating_execution
private javax.microedition.lcdui.Command get_heating_execution()
This method returns instance for heating_execution component and should be called instead of accessing heating_execution field directly.
Returns:
Instance for heating_execution component

get_heating_level
private javax.microedition.lcdui.Gauge get_heating_level()
This method returns instance for heating_level component and should be called instead of accessing heating_level field directly.
Returns:
Instance for heating_level component

get_heating_value
private javax.microedition.lcdui.StringItem get_heating_value()
This method returns instance for heating_value component and should be called instead of accessing heating_value field directly.
Returns:
Instance for heating_value component

get_imageItem1
private javax.microedition.lcdui.ImageItem get_imageItem1()
This method returns instance for imageItem1 component and should be called instead of accessing imageItem1 field directly.
Returns:
Instance for imageItem1 component

get_imageItem2
private javax.microedition.lcdui.ImageItem get_imageItem2()
This method returns instance for imageItem2 component and should be called instead of accessing imageItem2 field directly.
Returns:
Instance for imageItem2 component

get_imageItem3
private javax.microedition.lcdui.ImageItem get_imageItem3()
This method returns instance for imageItem3 component and should be called instead of accessing imageItem3 field directly.
Returns:
Instance for imageItem3 component

get_imageItem_heater
private javax.microedition.lcdui.ImageItem get_imageItem_heater()
This method returns instance for imageItem_heater component and should be called instead of accessing imageItem_heater field directly.
Returns:
Instance for imageItem_heater component

get_imageItem_light
private javax.microedition.lcdui.ImageItem get_imageItem_light()
This method returns instance for imageItem_light component and should be called instead of accessing imageItem_light field directly.
Returns:
Instance for imageItem_light component

get_imageItem_main
private javax.microedition.lcdui.ImageItem get_imageItem_main()
This method returns instance for imageItem_main component and should be called instead of accessing imageItem_main field directly.
Returns:
Instance for imageItem_main component

get_imageItem_profile_m
private javax.microedition.lcdui.ImageItem get_imageItem_profile_m()
This method returns instance for imageItem_profile_m component and should be called instead of accessing imageItem_profile_m field directly.
Returns:
Instance for imageItem_profile_m component

get_imageItem_schedule
private javax.microedition.lcdui.ImageItem get_imageItem_schedule()
This method returns instance for imageItem_schedule component and should be called instead of accessing imageItem_schedule field directly.
Returns:
Instance for imageItem_schedule component

get_image_door
private javax.microedition.lcdui.Image get_image_door()
This method returns instance for image_door component and should be called instead of accessing image_door field directly.
Returns:
Instance for image_door component

get_image_door_s
private javax.microedition.lcdui.Image get_image_door_s()
This method returns instance for image_door_s component and should be called instead of accessing image_door_s field directly.
Returns:
Instance for image_door_s component

get_image_heater
private javax.microedition.lcdui.Image get_image_heater()
This method returns instance for image_heater component and should be called instead of accessing image_heater field directly.
Returns:
Instance for image_heater component

get_image_heater_s
private javax.microedition.lcdui.Image get_image_heater_s()
This method returns instance for image_heater_s component and should be called instead of accessing image_heater_s field directly.
Returns:
Instance for image_heater_s component

get_image_light
private javax.microedition.lcdui.Image get_image_light()
This method returns instance for image_light component and should be called instead of accessing image_light field directly.
Returns:
Instance for image_light component

get_image_light_s
private javax.microedition.lcdui.Image get_image_light_s()
This method returns instance for image_light_s component and should be called instead of accessing image_light_s field directly.
Returns:
Instance for image_light_s component

get_image_profile_m
private javax.microedition.lcdui.Image get_image_profile_m()
This method returns instance for image_profile_m component and should be called instead of accessing image_profile_m field directly.
Returns:
Instance for image_profile_m component

get_image_profile_m_s
private javax.microedition.lcdui.Image get_image_profile_m_s()
This method returns instance for image_profile_m_s component and should be called instead of accessing image_profile_m_s field directly.
Returns:
Instance for image_profile_m_s component

get_image_profile_w
private javax.microedition.lcdui.Image get_image_profile_w()
This method returns instance for image_profile_w component and should be called instead of accessing image_profile_w field directly.
Returns:
Instance for image_profile_w component

get_image_profile_w_s
private javax.microedition.lcdui.Image get_image_profile_w_s()
This method returns instance for image_profile_w_s component and should be called instead of accessing image_profile_w_s field directly.
Returns:
Instance for image_profile_w_s component

get_image_schedule
private javax.microedition.lcdui.Image get_image_schedule()
This method returns instance for image_schedule component and should be called instead of accessing image_schedule field directly.
Returns:
Instance for image_schedule component

get_image_schedule_s
private javax.microedition.lcdui.Image get_image_schedule_s()
This method returns instance for image_schedule_s component and should be called instead of accessing image_schedule_s field directly.
Returns:
Instance for image_schedule_s component

get_image_ubiMobile
private javax.microedition.lcdui.Image get_image_ubiMobile()
This method returns instance for image_ubiMobile component and should be called instead of accessing image_ubiMobile field directly.
Returns:
Instance for image_ubiMobile component

get_image_ubimobile_s
private javax.microedition.lcdui.Image get_image_ubimobile_s()
This method returns instance for image_ubimobile_s component and should be called instead of accessing image_ubimobile_s field directly.
Returns:
Instance for image_ubimobile_s component

get_itemCommand1
private javax.microedition.lcdui.Command get_itemCommand1()
This method returns instance for itemCommand1 component and should be called instead of accessing itemCommand1 field directly.
Returns:
Instance for itemCommand1 component

get_lighting_execution
private javax.microedition.lcdui.Command get_lighting_execution()
This method returns instance for lighting_execution component and should be called instead of accessing lighting_execution field directly.
Returns:
Instance for lighting_execution component

get_lighting_level
private javax.microedition.lcdui.Gauge get_lighting_level()
This method returns instance for lighting_level component and should be called instead of accessing lighting_level field directly.
Returns:
Instance for lighting_level component

get_lighting_value
private javax.microedition.lcdui.StringItem get_lighting_value()
This method returns instance for lighting_value component and should be called instead of accessing lighting_value field directly.
Returns:
Instance for lighting_value component

get_profile_save
private javax.microedition.lcdui.Command get_profile_save()
This method returns instance for profile_save component and should be called instead of accessing profile_save field directly.
Returns:
Instance for profile_save component

get_schedule_delete
private javax.microedition.lcdui.Command get_schedule_delete()
This method returns instance for schedule_delete component and should be called instead of accessing schedule_delete field directly.
Returns:
Instance for schedule_delete component

get_schedule_duration
private javax.microedition.lcdui.TextField get_schedule_duration()
This method returns instance for schedule_duration component and should be called instead of accessing schedule_duration field directly.
Returns:
Instance for schedule_duration component

get_schedule_edit
private javax.microedition.lcdui.Command get_schedule_edit()
This method returns instance for schedule_edit component and should be called instead of accessing schedule_edit field directly.
Returns:
Instance for schedule_edit component

get_schedule_event
private javax.microedition.lcdui.ChoiceGroup get_schedule_event()
This method returns instance for schedule_event component and should be called instead of accessing schedule_event field directly.
Returns:
Instance for schedule_event component

get_schedule_list
private javax.microedition.lcdui.List get_schedule_list()
This method returns instance for schedule_list component and should be called instead of accessing schedule_list field directly.
Returns:
Instance for schedule_list component

get_schedule_place
private javax.microedition.lcdui.ChoiceGroup get_schedule_place()
This method returns instance for schedule_place component and should be called instead of accessing schedule_place field directly.
Returns:
Instance for schedule_place component

get_schedule_save
private javax.microedition.lcdui.Command get_schedule_save()
This method returns instance for schedule_save component and should be called instead of accessing schedule_save field directly.
Returns:
Instance for schedule_save component

get_schedule_time
private javax.microedition.lcdui.DateField get_schedule_time()
This method returns instance for schedule_time component and should be called instead of accessing schedule_time field directly.
Returns:
Instance for schedule_time component

get_schedule_update
private javax.microedition.lcdui.Command get_schedule_update()
This method returns instance for schedule_update component and should be called instead of accessing schedule_update field directly.
Returns:
Instance for schedule_update component

get_screenCommand_controllist
private javax.microedition.lcdui.Command get_screenCommand_controllist()
This method returns instance for screenCommand_controllist component and should be called instead of accessing screenCommand_controllist field directly.
Returns:
Instance for screenCommand_controllist component

get_screenCommand_scheduler
private javax.microedition.lcdui.Command get_screenCommand_scheduler()
This method returns instance for screenCommand_scheduler component and should be called instead of accessing screenCommand_scheduler field directly.
Returns:
Instance for screenCommand_scheduler component

get_screenCommand_search
private javax.microedition.lcdui.Command get_screenCommand_search()
This method returns instance for screenCommand_search component and should be called instead of accessing screenCommand_search field directly.
Returns:
Instance for screenCommand_search component

get_screenCommand_userprofile
private javax.microedition.lcdui.Command get_screenCommand_userprofile()
This method returns instance for screenCommand_userprofile component and should be called instead of accessing screenCommand_userprofile field directly.
Returns:
Instance for screenCommand_userprofile component

get_security_execution
private javax.microedition.lcdui.Command get_security_execution()
This method returns instance for security_execution component and should be called instead of accessing security_execution field directly.
Returns:
Instance for security_execution component

get_stringItem_profile_info
private javax.microedition.lcdui.StringItem get_stringItem_profile_info()
This method returns instance for stringItem_profile_info component and should be called instead of accessing stringItem_profile_info field directly.
Returns:
Instance for stringItem_profile_info component

get_stringItem_time
private javax.microedition.lcdui.StringItem get_stringItem_time()
This method returns instance for stringItem_time component and should be called instead of accessing stringItem_time field directly.
Returns:
Instance for stringItem_time component

get_textField1
private javax.microedition.lcdui.TextField get_textField1()
This method returns instance for textField1 component and should be called instead of accessing textField1 field directly.
Returns:
Instance for textField1 component

get_textField_email
private javax.microedition.lcdui.TextField get_textField_email()
This method returns instance for textField_email component and should be called instead of accessing textField_email field directly.
Returns:
Instance for textField_email component

get_textField_id
private javax.microedition.lcdui.TextField get_textField_id()
This method returns instance for textField_id component and should be called instead of accessing textField_id field directly.
Returns:
Instance for textField_id component

get_textField_password
private javax.microedition.lcdui.TextField get_textField_password()
This method returns instance for textField_password component and should be called instead of accessing textField_password field directly.
Returns:
Instance for textField_password component

initialize
private void initialize()
This method initializes UI of the application.

log
public static void log(String s)
An utility function to display a log message
Parameters:
s String

pauseApp
public void pauseApp()

profile_load
public void profile_load()
A method to load User Profile information from Record Store

profile_save
public void profile_save()
A method to save User Profile information into Record Store

set_form_main
public void set_form_main()
A method to display main form

set_ready
public void set_ready()
A method to ready for Bluetooth & send the first confirm message

startApp
public void startApp()