Package com.zebra.rfid.api3
Class RFIDReader
- java.lang.Object
-
- com.zebra.rfid.api3.RFIDReader
-
public class RFIDReader extends java.lang.ObjectProvides the RFIDReader object.
-
-
Field Summary
Fields Modifier and Type Field Description ActionsActionsInstance of Actions Class for all Actions related Operation like Inventory,Access.ConfigConfigInstance of Config Class for all Config related Operationsstatic intDEFAULT_LLRP_TXN_RSP_TIMEOUTEventsEventsInstance of Event Class for all Event related OperationsIRFIDLoggerLoggerstatic IRFIDLoggerLOGGERstatic intm_defaultLLRPTransactReceiveRespTimeReaderCapabilitiesReaderCapabilitiesAccess the Reader Capabilitiescom.zebra.rfid.api3.SecureConnectionInfoSecureConnectionInfo
-
Constructor Summary
Constructors Constructor Description RFIDReader()The constructorRFIDReader(java.lang.String hostName, int port, int timeoutMilliseconds)Constructor takes host name or IP address, port and timeout as parameterRFIDReader(java.lang.String hostName, int port, int timeoutMilliseconds, java.lang.String Protocol, java.lang.String Transport)Constructor takes host name or IP address, port and timeout as parameter
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidAcceptConnection(long readerSocket)voidconnect()Connects to the readervoiddisconnect()Disconnect from the readervoidDispose()Disposes the RFIDReaderprotected voidfinalize()java.lang.StringgetHostName()Gets the host name or IP Address of the readerjava.lang.StringgetPassword()intgetPort()Gets the port number which is used for establishing connection with the readerintgetTimeout()Gets the timeout of the reader connectionjava.lang.StringgetTransport()booleanisCapabilitiesReceived()Returns the current reader capabilities statusbooleanisConnected()Returns the current reader connection statusvoidPostConnectReaderUpdate()Update reader caps and init again in case of region and batch mode and password scenariosvoidreconnect()Reconnects to the reader, if the connection is lost.voidreinitTransport()voidsecureConnection(boolean isEnabled)voidsetHostName(java.lang.String hostName)Sets the host name or IP Address of the readervoidsetPassword(java.lang.String password)voidsetPort(int port)Sets the port number which is used for establishing connection with the reader.voidsetTimeout(int timeout)Sets the Time out for the response from the Reader, if specified zero(0), the default time out 5000 (5sec) will be used.voidswitchMode()VersionInfoversionInfo()Gets the RFID class library version information
-
-
-
Field Detail
-
LOGGER
public static final IRFIDLogger LOGGER
-
Logger
public IRFIDLogger Logger
-
SecureConnectionInfo
public com.zebra.rfid.api3.SecureConnectionInfo SecureConnectionInfo
-
Config
public Config Config
Instance of Config Class for all Config related Operations
-
Actions
public Actions Actions
Instance of Actions Class for all Actions related Operation like Inventory,Access.
-
Events
public Events Events
Instance of Event Class for all Event related Operations
-
ReaderCapabilities
public ReaderCapabilities ReaderCapabilities
Access the Reader Capabilities
-
m_defaultLLRPTransactReceiveRespTime
public static int m_defaultLLRPTransactReceiveRespTime
-
DEFAULT_LLRP_TXN_RSP_TIMEOUT
public static final int DEFAULT_LLRP_TXN_RSP_TIMEOUT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
RFIDReader
public RFIDReader()
The constructor
-
RFIDReader
public RFIDReader(java.lang.String hostName, int port, int timeoutMilliseconds)Constructor takes host name or IP address, port and timeout as parameter- Parameters:
hostName- String containing the reader's Host name or IP Address of the Reader.port- Reader Port number, if specified as Zero (0), the default port 5084 will be usedtimeoutMilliseconds- Time out for the response from the Reader, if specified zero(0), the default time out 5000 (5sec) will be used. The lowest possible value could be 2sec. This value also translates to keep-alive timeout. If the connection to the reader was inactive (no keep-alive message from the Reader) for a time greater than 10 times the timeout, DISCONNECTION_EVENT will be triggered to the application, if the application has registered for the same.
-
RFIDReader
public RFIDReader(java.lang.String hostName, int port, int timeoutMilliseconds, java.lang.String Protocol, java.lang.String Transport)Constructor takes host name or IP address, port and timeout as parameter- Parameters:
hostName- String containing the reader's Host name or IP Address of the Reader.port- Reader Port number, if specified as Zero (0), the default port 5084 will be usedtimeoutMilliseconds- Time out for the response from the Reader, if specified zero(0), the default time out 5000 (5sec) will be used. The lowest possible value could be 2sec. This value also translates to keep-alive timeout. If the connection to the reader was inactive (no keep-alive message from the Reader) for a time greater than 10 times the timeout, DISCONNECTION_EVENT will be triggered to the application, if the application has registered for the same.Protocol- ReaderTransport- Reader
-
-
Method Detail
-
PostConnectReaderUpdate
public void PostConnectReaderUpdate() throws InvalidUsageException, OperationFailureExceptionUpdate reader caps and init again in case of region and batch mode and password scenarios
-
finalize
protected void finalize() throws InvalidUsageException, OperationFailureException- Overrides:
finalizein classjava.lang.Object- Throws:
InvalidUsageExceptionOperationFailureException
-
Dispose
public void Dispose() throws java.lang.ExceptionDisposes the RFIDReader- Throws:
java.lang.Exception
-
getPort
public int getPort()
Gets the port number which is used for establishing connection with the reader
-
setPort
public void setPort(int port)
Sets the port number which is used for establishing connection with the reader. If Zero(0) specified, the default port 5084 will be used
-
getTimeout
public int getTimeout()
Gets the timeout of the reader connection
-
setTimeout
public void setTimeout(int timeout)
Sets the Time out for the response from the Reader, if specified zero(0), the default time out 5000 (5sec) will be used. The lowest possible value could be 2sec. This value also translates to keep-alive timeout. If the connection to the reader was inactive (no keep-alive message from the Reader) for a time greater than 10 times the timeout, DISCONNECTION_EVENT will be triggered to the application, if the application has registered for the same.
-
getHostName
public java.lang.String getHostName()
Gets the host name or IP Address of the reader
-
setHostName
public void setHostName(java.lang.String hostName)
Sets the host name or IP Address of the reader
-
getPassword
public java.lang.String getPassword()
-
setPassword
public void setPassword(java.lang.String password)
-
getTransport
public java.lang.String getTransport()
-
isConnected
public boolean isConnected()
Returns the current reader connection status
-
isCapabilitiesReceived
public boolean isCapabilitiesReceived()
Returns the current reader capabilities status
-
versionInfo
public VersionInfo versionInfo() throws InvalidUsageException
Gets the RFID class library version information- Returns:
- Throws:
InvalidUsageException
-
switchMode
public void switchMode()
-
connect
public void connect() throws InvalidUsageException, OperationFailureExceptionConnects to the reader
-
AcceptConnection
public void AcceptConnection(long readerSocket) throws InvalidUsageException, OperationFailureException
-
reinitTransport
public void reinitTransport()
-
reconnect
public void reconnect() throws InvalidUsageException, OperationFailureExceptionReconnects to the reader, if the connection is lost.
-
disconnect
public void disconnect() throws InvalidUsageException, OperationFailureExceptionDisconnect from the reader
-
secureConnection
public void secureConnection(boolean isEnabled)
-
-