|
WebObjects 5.2.3 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.webobjects.eoaccess.EOAdaptor
com.webobjects.jndiadaptor.JNDIAdaptor
The JNDIAdaptor class represents a Java Naming and Directory Interface service.
| Nested Class Summary |
| Nested classes inherited from class com.webobjects.eoaccess.EOAdaptor |
EOAdaptor.Delegate |
| Field Summary | |
static String |
AuthenticationMethodKey
A connection dictionary key representing the authentication method. |
static String |
DefaultScopeKey
A connection dictionary key representing the default scope. |
static String |
InitialContextFactoryKey
A connection dictionary key representing the initial context factory. |
static String |
NoneKey
A connection dictionary value representing no authentication method. |
static String |
ObjectKey
A connection dictionary value representing object scope. |
static String |
OneLevelKey
A connection dictionary value representing one-level scope. |
static String |
PasswordKey
A connection dictionary key representing the password. |
static String |
PlugInClassNameKey
A connection dictionary key representing the plug-in class name. |
static String |
ServerUrlKey
A connection dictionary key representing the server URL. |
static String |
SubtreeKey
A connection dictionary value representing subtree scope. |
static String |
TimeoutKey
A connection dictionary key representing the timeout. |
static String |
UsernameKey
A connection dictionary key representing the username. |
| Constructor Summary | |
JNDIAdaptor(String name)
Creates a new instance of JNDIAdaptor. |
|
| Method Summary | |
void |
assertConnectionDictionaryIsValid()
An abstract method that should be implemented by subclasses to verify that the adaptor can connect to the database server with its connection dictionary. |
void |
assignExternalInfoForEntireModel(EOModel model)
Assigns database-specific characteristics to model. |
EOAdaptorContext |
createAdaptorContext()
An abstract method that should be implemented by subclasses to create and return a new EOAdaptorContext, or null if a new context can't be created. |
static EOEditingContext |
createEditingContext(String modelName,
String serverUrl,
String username,
String password)
Creates a new instance of EOEditingContext with the specified model, server URL, username, and password. |
Class |
defaultExpressionClass()
An abstract method that should be implemented by subclasses to return the subclass of EOSQLExpression used as the default expression class for the adaptor. |
EOSQLExpressionFactory |
expressionFactory()
An abstract method that supports changes made to EOSQLExpression and related classes and interfaces. |
NSArray |
externalTypesWithModel(EOModel model)
The default implementation returns an empty array. |
boolean |
isDroppedConnectionException(Exception exception)
The default implementation returns false. |
boolean |
isValidQualifierType(String typeName,
EOModel model)
An abstract method that should be implemented by subclasses to return true if an attribute of type typeName
can be used in a qualifier (an SQL WHERE clause) sent to the database server,
false otherwise. |
JNDIPlugIn |
plugIn()
Gets the instance of the plug-in class name specified in the connection dictionary. |
void |
setConnectionDictionary(NSDictionary dictionary)
Sets the adaptor's connection dictionary to dictionary,
which must only contain String, NSData, NSDictionary, and NSArray
objects. |
EOSchemaGeneration |
synchronizationFactory()
An abstract method that supports changes made to EOSQLExpression and related classes and interfaces. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final String AuthenticationMethodKey
public static final String DefaultScopeKey
public static final String InitialContextFactoryKey
public static final String NoneKey
public static final String ObjectKey
public static final String OneLevelKey
public static final String PasswordKey
public static final String PlugInClassNameKey
public static final String ServerUrlKey
public static final String SubtreeKey
public static final String TimeoutKey
public static final String UsernameKey
| Constructor Detail |
public JNDIAdaptor(String name)
JNDIAdaptor.
name - - name of adaptorEOAdaptor.EOAdaptor(String)| Method Detail |
public void assertConnectionDictionaryIsValid()
EOAdaptorAn actual connection is made when the first adaptor channel
is sent an openChannel message.
assertConnectionDictionaryIsValid in class EOAdaptorEOAdaptor.setConnectionDictionary(NSDictionary dictionary),
EOAdaptorChannel.openChannel()public void assignExternalInfoForEntireModel(EOModel model)
EOAdaptormodel. Used in
EOModeler to switch a model's adaptor. This method examines each entity
in model. If an entity's external name is not set and all of
the entity's attribute's external names are not set, then this method uses
assignExternalInfoForEntity and
assignExternalInfoForAttribute to assign external names. If the
entity's external name is set or if any of the entity's attributes' external
names are set, then the method doesn't assign external names to the entity
or any of its attributes. Regardless, this method assigns external types for
all the model's attributes. Recurses through entities and their attributes
calling the conversion methods above.
A subclass of EOAdaptor doesn't need to implement this method.
assignExternalInfoForEntireModel in class EOAdaptormodel - The model.EOAdaptor.assignExternalInfoForEntity(EOEntity entity),
EOAdaptor.assignExternalInfoForAttribute(EOAttribute attribute)public EOAdaptorContext createAdaptorContext()
EOAdaptornull if a new context can't be created.
A newly created EOAdaptor has no contexts.
createAdaptorContext in class EOAdaptorEOAdaptor.contexts()
public static EOEditingContext createEditingContext(String modelName,
String serverUrl,
String username,
String password)
EOEditingContext with the specified model, server URL, username, and password.
modelName - - the name of the modelserverUrl - - the server URL of the connection dictionaryusername - - the username of the connection dictionarypassword - - the password of the connection dictionary
- - JNDIAdaptorException - if modelName is nullEOEditingContextpublic Class defaultExpressionClass()
EOAdaptor
defaultExpressionClass in class EOAdaptorEOAdaptor.setExpressionClassName(
String sqlExpressionClassName,
String adaptorClassName)public EOSQLExpressionFactory expressionFactory()
EOAdaptor
expressionFactory in class EOAdaptorEOSQLExpressionpublic NSArray externalTypesWithModel(EOModel model)
EOAdaptormodel is an optional argument that can be used to supplement
the adaptor's set of database types with additional, user-defined database
types. Refer to your adaptor's documentation to determine whether, and how,
it uses the model for type mapping.
externalTypesWithModel in class EOAdaptormodel - An optional argument that can be used to supplement
the adaptor's set of database types with additional,
user-defined database types.
public boolean isDroppedConnectionException(Exception exception)
EOAdaptorfalse. Subclasses
that support database reconnection should implement this method to
allow for automatic database reconnection. This method should return
true if the exception is one that the adaptor can
attempt to recover from by reconnecting to the database,
false otherwise.
Invoked if an exception is thrown during fetching or saving. If
the adaptor returns true, it then attempts to reconnect
to the database and retries the operation. If the reconnection
attempt fails, the exception from the failure is thrown as usual. If
the adaptor returns false, reconnection isn't attempted
and the exception is thrown.
isDroppedConnectionException in class EOAdaptorexception - An exception object.
false by default.EOAdaptor.handleDroppedConnection(),
EOAdaptor.Delegate.reconnectionDictionaryForAdaptor(
EOAdaptor adaptor)
public boolean isValidQualifierType(String typeName,
EOModel model)
EOAdaptortrue if an attribute of type typeName
can be used in a qualifier (an SQL WHERE clause) sent to the database server,
false otherwise. typeName is the name of a type as
required by the database server. model is an optional argument
that can be used to supplement the adaptor's set of type mappings with
additional mappings for user-defined database types.
isValidQualifierType in class EOAdaptortypeName - The name of a type as determined by the database server.model - A model.
true if an attribute of type
typeName can be used in a qualifier.public JNDIPlugIn plugIn()
JNDIPlugInJNDIPlugInpublic void setConnectionDictionary(NSDictionary dictionary)
EOAdaptordictionary,
which must only contain String, NSData, NSDictionary, and NSArray
objects. Connection information can not be changed while the adaptor
is connected. Throws an exception if there are any open channels
when this method is invoked.
Subclasses of EOAdaptor don't need to override this method.
A subclass that does override this method must incorporate the
superclass's version by calling super.
setConnectionDictionary in class EOAdaptordictionary - The adaptor's connection dictionary.EOAdaptor.connectionDictionary(),
EOAdaptor.hasOpenChannels(),
EOAdaptor.assertConnectionDictionaryIsValid()public EOSchemaGeneration synchronizationFactory()
EOAdaptor
synchronizationFactory in class EOAdaptorEOSQLExpression
|
Last updated Thu Oct 21 15:04:16 PDT 2004. | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||