com.simba.dsi.core.interfaces
Interface IDriver

All Known Implementing Classes:
DSIDriver

public interface IDriver

An IDriver handles driver properties and environments.


Method Summary
 com.simba.support.security.ICredentialFactory createCredentialFactory()
          Creates a credential factory for integrated security (Kerberos) credentials.
 IEnvironment createEnvironment()
          Factory method for creating IEnvironments.
 void deregister()
          Method called by DriverManager.deregisterDriver(Driver) to notify the JDBC driver that it was de-registered.
 com.simba.support.ILogger getDriverLog()
          Gets the driver-wide ILogger logging interface.
 IEventHandler getEventHandler()
          Gets the event handler interface.
 java.util.Locale getLocale()
          Gets the driver-wide locale.
 com.simba.support.IMessageSource getMessageSource()
          Gets the IMessageSource object for this driver.
 Variant getProperty(int propKey)
          Gets the property as identified by the given property key.
 

Method Detail

createEnvironment

IEnvironment createEnvironment()
                               throws com.simba.support.exceptions.ErrorException
Factory method for creating IEnvironments.

Returns:
IEnvironment.
Throws:
com.simba.support.exceptions.ErrorException - If an error occurs.
See Also:
IEnvironment

getDriverLog

com.simba.support.ILogger getDriverLog()
Gets the driver-wide ILogger logging interface.

Returns:
Log for driver-wide logging.

getEventHandler

IEventHandler getEventHandler()
Gets the event handler interface.

Returns:
Event handler.

getLocale

java.util.Locale getLocale()
Gets the driver-wide locale. The locale is read from SettingReader, which defaults to the JVM default locale. The locale is composed of a 2-letter (lower case) language code, and an optional 2-letter (upper case) country code. If a country code is included, the two codes _MUST_ be separated by a hyphen (-). The language codes conform to the ISO 639-1 standard. http://www.loc.gov/standards/iso639-2/php/code_list.php The country codes conform to the ISO 3166-1 Alpha-2 code standard. http://www.iso.org/iso/country_codes/iso-3166-1_decoding_table.htm Examples: en-US (English - United States) fr-CA (French - Canada) it-IT (Italian - Italy) de-DE (German - Germany) es-ES (Spanish - Spain (Traditional)) ja (Japanese)

Returns:
The locale for this connection.

getMessageSource

com.simba.support.IMessageSource getMessageSource()
Gets the IMessageSource object for this driver.

Returns:
The message source associated with this driver.

getProperty

Variant getProperty(int propKey)
                    throws BadPropertyKeyException,
                           com.simba.support.exceptions.ErrorException
Gets the property as identified by the given property key.

Parameters:
propKey - Property key associated with an driver property.
Returns:
the property value associated with the given property key.
Throws:
BadPropertyKeyException - If the given property key is not found.
com.simba.support.exceptions.ErrorException - If an error occurs.
See Also:
Variant

createCredentialFactory

com.simba.support.security.ICredentialFactory createCredentialFactory()
Creates a credential factory for integrated security (Kerberos) credentials. A new Credential Factory may be created per connection to construct new Credentials each time. This is only called if the DSI_DRIVER_SUPPORTS_INTEGRATED_SECURITY DSI Driver Property has been set.

Returns:
An ICredentialFactory.

deregister

void deregister()
Method called by DriverManager.deregisterDriver(Driver) to notify the JDBC driver that it was de-registered. The deregister method is intended only to be used by JDBC Drivers and not by applications. JDBC drivers are recommended to not implement DriverAction in a public class. If there are active connections to the database at the time that the deregister method is called, it is implementation specific as to whether the connections are closed or allowed to continue. Once this method is called, it is implementation specific as to whether the driver may limit the ability to create new connections to the database, invoke other Driver methods or throw a SQLException. NOTE: This method should only be implemented if using JDBC4.2 or higher because DriverAction interface with this method was introduced in Java 1.8 If this method wants to be used then the driver must be registered with JDBC42AbstractDriver



Copyright © 2006-2014 Simba Technologies Incorporated. All Rights Reserved.