|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.uddi.promoter.publish.KeyDetector
Checks entity specific database tables directly to detect if another entity type is using the specified key.
This can be used to ensure that entity keys are unique in the registry across entity types, as per the specification.
Field Summary | |
---|---|
static java.lang.String |
java_copyright
|
static java.lang.String |
KEY_NOT_USED
ID indicating the key does not exist in the registry. |
static java.lang.String |
KEY_USED_IN_BINDING
ID indicating the key exists in the binding table. |
static java.lang.String |
KEY_USED_IN_BUSINESS
ID indicating the key exists in the business table. |
static java.lang.String |
KEY_USED_IN_SERVICE
ID indicating the key exists in the service table. |
static java.lang.String |
KEY_USED_IN_TMODEL
ID indicating the key exists in the tModel table. |
Fields inherited from interface com.ibm.uddi.promoter.CommandLineConstants |
---|
ARG_BINDING, ARG_BUSINESS, ARG_DEFINITION_FILE, ARG_DELETE, ARG_EXPORT, ARG_IMPORT, ARG_IMPORT_REFERENCED_ENTITIES, ARG_INPUT_KEYFILE, ARG_INPUT_KEYFILE_OLD, ARG_OVERWRITE, ARG_OVERWRITE_OLD, ARG_PROMOTE, ARG_PROPERTIES_FILE, ARG_SERVICE, ARG_TMODEL, ARG_VERBOSE, ARG_VERBOSE_OLD, USAGE |
Constructor Summary | |
---|---|
KeyDetector(java.sql.Connection connection)
Constructor taking a Connection . |
Method Summary | |
---|---|
java.lang.String |
findTableContainingKey(java.lang.String entityKey)
Returns the name of the table that contains the specified key. |
java.sql.Connection |
getConnection()
Returns the connection. |
boolean |
keyUsedInBinding(java.lang.String entityKey)
Searches binding table for existence of specified key. |
boolean |
keyUsedInBusiness(java.lang.String entityKey)
Searches business table for existence of specified key. |
boolean |
keyUsedInService(java.lang.String entityKey)
Searches service table for existence of specified key |
boolean |
keyUsedInTModel(java.lang.String entityKey)
Searches tModel table for existence of specified key. |
void |
setConnection(java.sql.Connection connection)
Sets the connection. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String java_copyright
public static final java.lang.String KEY_NOT_USED
public static final java.lang.String KEY_USED_IN_BUSINESS
public static final java.lang.String KEY_USED_IN_SERVICE
public static final java.lang.String KEY_USED_IN_BINDING
public static final java.lang.String KEY_USED_IN_TMODEL
Constructor Detail |
public KeyDetector(java.sql.Connection connection) throws PromoterDBException
Connection
.
connection
- PromoterDBException
- Method Detail |
public boolean keyUsedInBusiness(java.lang.String entityKey) throws PromoterDBException
entityKey
- true
if the key exists in the business table.public boolean keyUsedInService(java.lang.String entityKey) throws PromoterDBException
entityKey
- true
if the key exists in the service table.public boolean keyUsedInBinding(java.lang.String entityKey) throws PromoterDBException
entityKey
- true
if the key exists in the binding table.public boolean keyUsedInTModel(java.lang.String entityKey) throws PromoterDBException
entityKey
- true
if the key exists in the tModel table.public java.lang.String findTableContainingKey(java.lang.String entityKey) throws PromoterDBException
entityKey
- PromoterDBException
- KEY_NOT_USED
,
KEY_USED_IN_BUSINESS
,
KEY_USED_IN_SERVICE
,
KEY_USED_IN_BINDING
,
KEY_USED_IN_TMODEL
public java.sql.Connection getConnection()
public void setConnection(java.sql.Connection connection)
connection
- The connection to set
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |