public class SPECCHIODatabaseDescriptor extends java.lang.Object implements SPECCHIOServerDescriptor
| Constructor and Description |
|---|
SPECCHIODatabaseDescriptor(java.lang.String[] tokens)
Constructor for SPECCHIOClientFactory.process_line().
|
SPECCHIODatabaseDescriptor(java.lang.String server,
int port,
java.lang.String schema,
java.lang.String dataSourceName)
Constructor for an anonymous connection to the database.
|
SPECCHIODatabaseDescriptor(java.lang.String server,
int port,
java.lang.String schema,
java.lang.String dataSourceName,
java.lang.String user,
java.lang.String password)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
SPECCHIOClient |
createClient()
Create a web client that can connect to the server represented by
this descriptor.
|
java.lang.String |
getAccountConfigurationString()
Get the string describing the account configuration for db_config.txt
|
java.lang.String |
getDatabaseName()
The the database name.
|
java.lang.String |
getDataSourceName()
Get a name of the datasource (JNDI).
|
java.lang.String |
getDisplayName(boolean showUser,
boolean show_datasource_name)
Get the display name of this server.
|
java.lang.String |
getDisplayUser()
Get the user name.
|
int |
getList_index()
index at which this descriptor is found in the list of known connections
|
java.lang.String |
getPassword()
Get the password.
|
int |
getPort()
Get the port number.
|
java.lang.String |
getPreferenceNodeName()
Get the node name in preferences or line number in legacy file
|
java.lang.String |
getServer()
Get the database server name.
|
java.lang.Boolean |
isEncrypted()
Defines if this connection is encrypted
|
void |
setDataSourceName(java.lang.String dataSourceName) |
void |
setList_index(int list_index)
set index at which this descriptor is found in the list of known connections
|
void |
setUser(User user)
Set the user information associated with this account.
|
java.lang.String |
toString()
Get a string representation of the server.
|
java.lang.Boolean |
usesDefaultTrustStore()
Defines if this connection relies on the default JVM trust store
|
public SPECCHIODatabaseDescriptor(java.lang.String server,
int port,
java.lang.String schema,
java.lang.String dataSourceName,
java.lang.String user,
java.lang.String password)
server - the database host nameport - the database port numberschema - the database schema nameuser - the usernamepassword - the passwordpublic SPECCHIODatabaseDescriptor(java.lang.String server,
int port,
java.lang.String schema,
java.lang.String dataSourceName)
server - the database host nameport - the database port numberschema - the database schema nameuser - the usernamepassword - the passwordpublic SPECCHIODatabaseDescriptor(java.lang.String[] tokens)
throws SPECCHIODatabaseClientException
tokens - the array of strings read from the input fileSPECCHIODatabaseClientException - the tokens are not correctly formattedpublic SPECCHIOClient createClient()
createClient in interface SPECCHIOServerDescriptorpublic java.lang.String getAccountConfigurationString()
public java.lang.String getDatabaseName()
public java.lang.String getDisplayName(boolean showUser,
boolean show_datasource_name)
getDisplayName in interface SPECCHIOServerDescriptorshowUser - include the user account details in the display?show_datasource_name - include the JNDI details in the display?public java.lang.String getDisplayUser()
getDisplayUser in interface SPECCHIOServerDescriptorpublic java.lang.String getPassword()
public int getPort()
public java.lang.String getServer()
public void setUser(User user)
setUser in interface SPECCHIOServerDescriptoruser - the user informationpublic java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String getDataSourceName()
SPECCHIOServerDescriptorgetDataSourceName in interface SPECCHIOServerDescriptorpublic void setDataSourceName(java.lang.String dataSourceName)
public java.lang.String getPreferenceNodeName()
SPECCHIOServerDescriptorgetPreferenceNodeName in interface SPECCHIOServerDescriptorpublic java.lang.Boolean usesDefaultTrustStore()
SPECCHIOServerDescriptorusesDefaultTrustStore in interface SPECCHIOServerDescriptorpublic java.lang.Boolean isEncrypted()
SPECCHIOServerDescriptorisEncrypted in interface SPECCHIOServerDescriptorpublic int getList_index()
SPECCHIOServerDescriptorgetList_index in interface SPECCHIOServerDescriptorpublic void setList_index(int list_index)
SPECCHIOServerDescriptorsetList_index in interface SPECCHIOServerDescriptor