|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcom.starmicronics.stario.StarProxiPRNTManager
public final class StarProxiPRNTManager
| Field Summary | |
|---|---|
static java.lang.String |
KEY_STAR_DEVICETYPE
|
static java.lang.String |
KEY_STAR_MACADDRESS
|
static java.lang.String |
KEY_STAR_NICKNAME
|
static java.lang.String |
KEY_STAR_PORTSETTIGS
|
static java.lang.String |
KEY_STAR_THRESHOLDRSSI
|
static java.lang.String |
KEY_STAR_WITHDRAWER
|
| Method Summary | |
|---|---|
void |
addSettingForDKAirCashPortName(java.lang.String portName,
java.lang.String portSettings,
java.lang.String macAddress,
int threshold,
java.lang.String nickName)
Adds the settings of the DK-AirCash to be connected with the BLED10-U. |
void |
addSettingForPrinterPortName(java.lang.String portName,
java.lang.String portSettings,
boolean withDrawer,
java.lang.String macAddress,
int threshold,
java.lang.String nickName)
|
int |
calibrateActionArea(java.lang.String bleMacAddress)
Calibrate RSSI to make action area. |
boolean |
deserializeSetting(byte[] settingsByteArray)
Set deserialize settings by specified byte array settings |
java.util.HashMap<java.lang.String,java.util.HashMap<java.lang.String,java.lang.Object>> |
getAllSettings()
Gets all setting information connected to the BLED10-U by the port name |
StarProxiPRNTManagerCallback |
getCallback()
This method acquires the StarProxiPRNTManagerCallback object. |
java.lang.String |
getClosestCashDrawer()
When the RSSI value exceeds the threshold, gets the port name of the POS Printer. |
java.lang.String |
getClosestPrinter()
When the RSSI value exceeds the threshold, gets the port name of the DK-AirCash. |
int |
getRSSI(java.lang.String macAddress)
Gets the RSSI value of the connected printer or DK-AirCash. |
java.util.HashMap<java.lang.String,java.lang.Object> |
getSettings(java.lang.String portName)
Gets the setting information connected to the BLED10-U by the port name. In getting device type (DK-AirCash or Printer), specify the "StarProxiPRNTManager.KEY_STAR_DEVICETYPE" to key In getting presence/absence information (true/false), specify the "StarProxiPRNTManager.KEY_STAR_WITHDRAWER" to key In getting NicName to connect the BLED10-U and the POSPrinter or DK-AirCash, specify the "StarProxiPRNTManager.KEY_STAR_NICKNAME" to key In getting portSettings, specify the "StarProxiPRNTManager.KEY_STAR_PORTSETTINGS" to key In getting threshold value, specify the "StarProxiPRNTManager.KEY_STAR_THRESHOLDRSSI" to key In getting Mac address of BLED10-U, specify the "StarProxiPRNTManager.KEY_STAR_MACADDRESS" to key |
static StarProxiPRNTManager |
getSharedManager()
Gets an instance of StarProxiPRNTManager |
void |
removeSettingsWithPortName(java.lang.String portName)
This method removes the setting information connected to the BLED10-U by the port name. |
byte[] |
serializedSettings()
Get byte array value by serialized settings |
void |
setCallback(StarProxiPRNTManagerCallback callback)
This method sets a callback. See StarProxiPRNTManagerCallback interface for the callback function. |
boolean |
startScan()
Start scanning Bluetooth Low Energy devices. Do not execute this method when printing data or opening the drawer. Execute stopScan method and stop scanning BLE device before printing data or opening the drawer. |
boolean |
startScan(int samplingNumber)
Start scanning Bluetooth Low Energy devices. Do not execute this method when printing data or opening the drawer. Execute stopScan method and stop scanning BLE device before printing data or opening the drawer. |
void |
stopScan()
Stop scanning Bluetooth Low Energy devices. Execute stopScan method and stop scanning BLE device before printing data or opening the drawer. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String KEY_STAR_MACADDRESS
public static final java.lang.String KEY_STAR_PORTSETTIGS
public static final java.lang.String KEY_STAR_DEVICETYPE
public static final java.lang.String KEY_STAR_WITHDRAWER
public static final java.lang.String KEY_STAR_THRESHOLDRSSI
public static final java.lang.String KEY_STAR_NICKNAME
| Method Detail |
|---|
public static StarProxiPRNTManager getSharedManager()
throws StarIOPortException
StarIOPortException - If Android OS Version is earlier than API Level:18.
public boolean startScan()
throws StarIOPortException
StarIOPortException - If Android OS Version is earlier than API Level:18.
public boolean startScan(int samplingNumber)
throws StarIOPortException
samplingNumber - 3 or 7 or 10 can specified.
StarIOPortException - If Android OS Version is earlier than API Level:18. Or sampling Number is not match.
public void stopScan()
throws StarIOPortException
StarIOPortException - If Android OS Version is earlier than API Level:18.
public int getRSSI(java.lang.String macAddress)
throws StarIOPortException
macAddress - macAddress of BLED10-U to use
StarIOPortException - If Android OS Version is earlier than API Level:18.
public void addSettingForPrinterPortName(java.lang.String portName,
java.lang.String portSettings,
boolean withDrawer,
java.lang.String macAddress,
int threshold,
java.lang.String nickName)
throws StarIOPortException
portName - Identifies the POSprinter to use
| Ethernet and WiFi: Usage - | TCP:IPAddress | (eg, TCP:192.168.1.23) | |
| BlueTooth: Usage - | BT: | (finds and uses the first star BlueTooth printer paired with your device) | |
| BT:DeviceName | (eg, BT:StarMicronics) | ||
| BT:<MacAddress> | (eg, BT:00:15:0E:45:00:12) |
PortSettings - The settings for the port
| Ethernet Settings: | |||
| Examples: | "" | BlueTooth Settings: | "" - | Using a POSprinter (No portSettings are required when using other Interface and "SSP" by Bluetooth Interface.) |
| ;p - | Using a POSprinter(If use the "PIN Code" by Bluetooth Interface) | ||
| Examples: | "", ";p" |
withDrawer - Presence/absence of a cash drawer.macAddress - Mac address of the BLED10-U.threshold - ThresholdnickName - Nick name to connect the BLED-10U and the POS Printer.
StarIOPortException
- If portName or macAddress is nullStarIOPortException
public void addSettingForDKAirCashPortName(java.lang.String portName,
java.lang.String portSettings,
java.lang.String macAddress,
int threshold,
java.lang.String nickName)
throws StarIOPortException
portName - Identifies the DK-AirCash to use
| Ethernet and WiFi: Usage - | TCP:IPAddress | (eg, TCP:192.168.1.23) | |
| BlueTooth: Usage - | BT: | (finds and uses the first star BlueTooth printer paired with your device) | |
| BT:DeviceName | (eg, BT:StarMicronics) | ||
| BT:<MacAddress> | (eg, BT:00:15:0E:45:00:12) |
PortSettings - The settings for the port
| Ethernet Settings: | |||
| Examples: | "" | BlueTooth Settings: | "" - | Using a DK-AirCash (No portSettings are required when using other Interface and "SSP" by Bluetooth Interface.) |
| ;p - | Using a DK-AirCash(If use the "PIN Code" by Bluetooth Interface) | ||
| Examples: | "", ";p" |
macAddress - Mac address of the BLED10-U.threshold - ThresholdnickName - Nick name to connect the BLED-10U and the DK-AirCash.
StarIOPortException
- If portName or macAddress is nullStarIOPortException
public void removeSettingsWithPortName(java.lang.String portName)
throws StarIOPortException
portName - A port name to delete settings
StarIOPortException
- If the specified portName is nullStarIOPortExceptionpublic byte[] serializedSettings()
public boolean deserializeSetting(byte[] settingsByteArray)
throws StarIOPortException
settingsByteArray - Value obtained from serializedSettings method
StarIOPortException - If settingsByteArray is null
public java.util.HashMap<java.lang.String,java.lang.Object> getSettings(java.lang.String portName)
throws StarIOPortException
portName - portName of POS Printer or DK-AirCash connected to the BLED10-U.
StarIOPortException
- If Android OS Version is earlier than API Level:18.
- If the specified portName is nullStarIOPortException
public java.util.HashMap<java.lang.String,java.util.HashMap<java.lang.String,java.lang.Object>> getAllSettings()
throws StarIOPortException
StarIOPortExceptionpublic void setCallback(StarProxiPRNTManagerCallback callback)
callback - specifies the object (StarProxiPRNTManagerCallback interface).public StarProxiPRNTManagerCallback getCallback()
public java.lang.String getClosestPrinter()
public java.lang.String getClosestCashDrawer()
public int calibrateActionArea(java.lang.String bleMacAddress)
throws StarIOPortException
bleMacAddress - of BLED10-10
StarIOPortException - If Android OS Version is earlier than API Level:18.
- If StartScan has been executed already
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||