Documentation Archive Developer
PATH  Documentation > WebObjects 4.5 > EOAccess Reference

Table of Contents


Inherits from: NSObject
Declared in: EOAccess/EOAdaptor.h

Class Description

EOLoginPanel is an abstract class that defines how users of an Enterprise Objects Framework application provide database login information. Concrete subclasses of EOLoginPanel override its one method to run a modal login panel. Unless you are writing a concrete adaptor subclass, you shouldn't need to interact with this class. Generally, the Framework automatically creates and runs an instance of a concrete login panel object when your application needs connection information for the user. If you want to control when or how the login panel is run, use the EOAdaptor methods runLoginPanelAndValidateConnectionDictionary and runLoginPanel. When invoked, these methods create a concrete EOLoginPanel and interact with it for you.

If you are writing a concrete adaptor, you must provide a concrete subclass of EOLoginPanel and a graphical user interface (usually a .nib file). Enterprise Objects Framework expects these resources to be provided in a bundle named "LoginPanel" in the adaptor's framework. See the class specification for EOAdaptor for more information.

Instance Methods


- (NSDictionary *)administrativeConnectionDictionaryForAdaptor:(EOAdaptor *)adaptor

Adaptor subclass should implement a subclass that implements this method. Returns nil if the user cancels the panel.


- (NSDictionary *)runPanelForAdaptor:(EOAdaptor *)adaptor validate:(BOOL)flag allowsCreation:(BOOL)allowsCreation

Implemented by subclasses to run the login panel, allowing a user to enter new connection information. Returns the new connection information or nil if the user cancels the panel. If flag is YES, this method runs the login panel until the user enters valid connection information or cancels the panel. If allowsCreation is YES, the panel will have an additional button that allows the user to create a new database, and will prompt them for any necessary administrative information. When valid login information is entered in the panel, it is stored in adaptor's connection dictionary and returned. Login information is validated by sending adaptor an assertConnectionDictionaryIsValid message.

If flag is NO, login information entered in the panel isn't validated and is returned without affecting the adaptor's connection dictionary.

A subclass must override this method without invoking EOAdaptor's implementation.

See Also: - setConnectionDictionary: (EOAdaptor), - assertConnectionDictionaryIsValid (EOAdaptor), - runLoginPanelAndValidateConnectionDictionary (EOAdaptor), - runLoginPanel (EOAdaptor)

Table of Contents