Documentation Archive Developer
Search
PATH Documentation > WebObjects

Table of Contents

EOStoredProcedure


Inherits from:
Object
Implements:
EOPropertyListEncoding
Package:
com.webobjects.eoaccess


Class Description


An EOStoredProcedure represents a stored procedure defined in a database, and associates a name internal to the Framework with an external name by which the stored procedure is known to the database. If a stored procedure has arguments, its EOStoredProcedure object also maintains a group of EOAttributes which represent the stored procedure's arguments. See the EOAttribute class specification for more information

You usually define stored procedures in your EOModel with the EOModeler application, which is documented in the Enterprise Objects Framework Developer's Guide. EOStoredProcedures are primarily used by the Enterprise Objects Framework to map operations for an EOEntity to stored procedures (see the description for EOEntity's setStoredProcedure method). You can assign stored procedures to an entity for any of the following scenarios:

Your code probably won't use EOStoredProcedures unless you're working at the adaptor level.

Like the other major modeling classes, EOStoredProcedure provides a user dictionary for your application to store any application-specific information related to the stored procedure.




Interfaces Implemented


EOPropertyListEncoding
awakeWithPropertyList
encodeIntoPropertyList


Method Types


Constructors
EOStoredProcedure
Accessing the model
model
Accessing the name
setName
beautifyName
name
Accessing the external name
setExternalName
externalName
Accessing the arguments
setArguments
arguments
Accessing the user dictionary
setUserInfo
userInfo


Constructors



EOStoredProcedure

public EOStoredProcedure(String name)

Description forthcoming.

public EOStoredProcedure( NSDictionary propertyList, Object owner)

Creates and returns a new EOStoredProcedure initialized from propertyList-a dictionary containing only property list data types (that is, String, NSDictionary, NSArray, and NSData). This constructor is used by EOModeler when it reads in an EOModel object from a file, for example. The owner argument should be the EOStoredProcedure's EOModel. EOStoredProcedures created from a property list must receive an awakeWithPropertyList message immediately after creation before they are fully functional, but the awake... message should be deferred until the all of the other objects in the model have also been created.

See Also: encodeIntoPropertyList (EOPropertyListEncoding) setName, name

Creates and returns a new EOStoredProcedure named name.


Instance Methods



arguments

public NSArray arguments()

Returns the EOAttribute objects that describe the stored procedure's arguments or null if the stored procedure has no arguments.

awakeWithPropertyList

public void awakeWithPropertyList(NSDictionary pList)

Description forthcoming.

beautifyName

public void beautifyName()

Renames the receiver's name and its arguments to conform to the Framework's naming conventions. For example, "NAME" is renamed "name" and "FIRST_NAME" is renamed "firstName". This method is used in reverse-engineering a model.

See Also: setArguments, beautifyNames (EOModel)



encodeIntoPropertyList

public void encodeIntoPropertyList(NSMutableDictionary pList)

Description forthcoming.

externalName

public String externalName()

Returns the name of the stored procedure as it is defined in the database, or null if the receiver doesn't have an external name.

See Also: setExternalName



model

public EOModel model()

Returns the model to which the receiver belongs.

See Also: addStoredProcedure (EOModel)



name

public String name()

Returns the name of the receiver.

See Also: setName, EOStoredProcedure constructor



setArguments

public void setArguments(NSArray arguments)

Sets arguments as the array of EOAttributes that describe the receiver's arguments. The EOAttribute objects in arguments must be ordered to match the database stored procedure definition.

See Also: arguments



setExternalName

public void setExternalName(String name)

Sets the external name of the stored procedure to name. name should be the name of the stored procedure as it is defined in the database.

See Also: externalName



setName

public void setName(String name)

Sets the name of the receiver.

See Also: name, EOStoredProcedure constructor



setUserInfo

public void setUserInfo(NSDictionary dictionary)

Sets the dictionary of auxiliary data, which your application can use for whatever it needs. dictionary can only contain property list data types (that is, String, NSDictionary, NSArray, and NSData).

See Also: userInfo



toString

public String toString()

Description forthcoming.

userInfo

public NSDictionary userInfo()

Returns a dictionary of user data. Your application can use this to store any auxiliary information it needs.

See Also: setUserInfo



© 2001 Apple Computer, Inc. (Last Published April 13, 2001)


Table of Contents