|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.fosstrak.llrp.client.RepositoryFactory
public class RepositoryFactory
helper class to instantiate the repository.
Field Summary | |
---|---|
static java.lang.String |
ARG_DB_CLASSNAME
class name in the arguments table. |
static java.lang.String |
ARG_JDBC_STRING
JDBC string in the arguments table. |
static java.lang.String |
ARG_LOG_RO_ACCESS_REPORT
parameter whether to log RO_ACCESS_REPORT. |
static java.lang.String |
ARG_PASSWRD
password in the arguments table. |
static java.lang.String |
ARG_USERNAME
user-name in the arguments table. |
static java.lang.String |
ARG_WIPE_DB
parameter whether to wipe DB in the arguments table. |
static java.lang.String |
ARG_WIPE_RO_ACCESS_REPORTS_DB
parameter whether to wipe RO_ACCESS_REPORTS DB in the arguments table. |
Constructor Summary | |
---|---|
RepositoryFactory()
|
Method Summary | |
---|---|
static Repository |
create(java.util.Map<java.lang.String,java.lang.String> args)
create a new repository with the configuration parameters provided via the parameters hash map. |
static Repository |
create(java.util.Properties properties)
create a new repository and read the configuration from a Properties data structure. |
static java.util.Map<java.lang.String,java.lang.String> |
createMap(java.lang.String[][] keyValue)
helper to create a hash-map with key-value pairs. just provide a 2D array, with pairs of (key, value). |
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 ARG_USERNAME
public static final java.lang.String ARG_PASSWRD
public static final java.lang.String ARG_JDBC_STRING
public static final java.lang.String ARG_WIPE_DB
public static final java.lang.String ARG_LOG_RO_ACCESS_REPORT
public static final java.lang.String ARG_WIPE_RO_ACCESS_REPORTS_DB
public static final java.lang.String ARG_DB_CLASSNAME
Constructor Detail |
---|
public RepositoryFactory()
Method Detail |
---|
public static java.util.Map<java.lang.String,java.lang.String> createMap(java.lang.String[][] keyValue)
Map<String,String> m = createMap(new String[][] {
{key1, value1},
{key2, value2},
{key3, value3}
}
keyValue
- the key values 2D array.
public static Repository create(java.util.Properties properties) throws java.lang.InstantiationException, LLRPRuntimeException, java.lang.IllegalAccessException, java.lang.ClassNotFoundException
properties
- the properties where to obtain the configuration from.
Repository
.
java.lang.InstantiationException
- when no instantiation was possible.
java.lang.IllegalAccessException
- access to class was denied.
java.lang.ClassNotFoundException
- when the class is not existing.
LLRPRuntimeException
- when something other went wrong.public static Repository create(java.util.Map<java.lang.String,java.lang.String> args) throws java.lang.InstantiationException, LLRPRuntimeException, java.lang.IllegalAccessException, java.lang.ClassNotFoundException
args
- a hash-map providing the parameters.
Repository
.
java.lang.InstantiationException
- when no instantiation was possible.
java.lang.IllegalAccessException
- access to class was denied.
java.lang.ClassNotFoundException
- when the class is not existing.
LLRPRuntimeException
- when something other went wrong.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |