|
Project Wonder 2.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object er.extensions.ERXEntityClassDescription.Factory
This factory inner class is registered as the observer for three notifications: modelWasAdded, classDescriptionNeededForEntity and classDescriptionNeededForClass. If you wish to provide your own subclass of ERXEntityClassDescription then you need to create a subclass of Factory and set that class name in the system properties under the key: er.extensions.ERXClassDescription.factoryClass In your Factory subclass override the method: newClassDescriptionForEntity to provide your own ERXEntityClassDescription subclass.
Constructor Summary | |
ERXEntityClassDescription.Factory()
Public constructor |
Method Summary | |
void |
applicationDidFinishLaunching(NSNotification n)
Method called by the WOApplication
has finished launching. |
void |
checkForeignKeys(EOEntity eoentity)
Checks for foreign keys that are NOT NULL ,
but whose relationship is marked as non-mandatory and vice-versa. |
void |
classDescriptionNeededForClass(NSNotification n)
Method called by the NSNotificationCenter
when a class description is needed
for a given Class. |
void |
classDescriptionNeededForEntityName(NSNotification n)
Method called by the NSNotificationCenter
when a class description is needed
for a given entity. |
void |
compilerProxyDidCompileClasses(NSNotification n)
Method called by the NSNotificationCenter
when an ERXCompilerProxy did reset. |
protected void |
handleMandatoryRelationshipError(EOEntity eoentity,
EORelationship relationship,
EOAttribute attribute)
Handles errors when a mandatory relationship has a source attribute that is set to not allow null values. |
protected void |
handleOptionalRelationshipError(EOEntity eoentity,
EORelationship relationship,
EOAttribute attribute)
Handles errors when an optional relationship has a source attribute that is set to allow null values. |
boolean |
isFixingRelationshipsEnabled()
|
boolean |
isRapidTurnaroundEnabled()
|
void |
modelWasAddedNotification(NSNotification n)
Method called by the NSNotificationCenter
when an EOModel is loaded.
|
ERXEntityClassDescription |
newClassDescriptionForEntity(EOEntity entity)
Factory method that is used to create a new class description for a given entity. |
void |
prepareEntityForRegistration(EOEntity eoentity)
Allows for entities to be altered before they have a custom class description registered. |
void |
registerDescriptionForClass(Class class1)
This method is called when a class description is needed for a particular class. |
void |
registerDescriptionForEntitiesInModel(EOModel model)
This method registers custom class descriptions for all of the entities in a given model. |
void |
registerDescriptionForEntity(EOEntity entity)
Registers a custom class description for the given entity using the method newClassDescriptionForEntity
which can be overridden by subclasses to provide a
different class description subclass. |
void |
reset()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ERXEntityClassDescription.Factory()
Method Detail |
public void reset()
public void compilerProxyDidCompileClasses(NSNotification n)
NSNotificationCenter
when an ERXCompilerProxy did reset.
public boolean isRapidTurnaroundEnabled()
public boolean isFixingRelationshipsEnabled()
public void applicationDidFinishLaunching(NSNotification n)
WOApplication
has finished launching.
public void modelWasAddedNotification(NSNotification n)
NSNotificationCenter
when an EOModel is loaded.
This method just calls the method
registerDescriptionForEntitiesInModel
n
- notification that has the EOModel that was loaded.public void classDescriptionNeededForEntityName(NSNotification n)
NSNotificationCenter
when a class description is needed
for a given entity. Usually this method isn't needed seeing
as we preempt the on demand loading of class descriptions
by loading all of them when the EOModel is loaded.
This method just calls the method
registerDescriptionForEntity
n
- notification that has the name of the entity
that needs the class description.public void classDescriptionNeededForClass(NSNotification n)
NSNotificationCenter
when a class description is needed
for a given Class. Usually this method isn't needed seeing
as we preempt the on demand loading of class descriptions
by loading all of them when the EOModel is loaded.
This method just calls the method
registerDescriptionForClass
n
- notification that has the Class object
that needs a class description.public ERXEntityClassDescription newClassDescriptionForEntity(EOEntity entity)
entity
- to create the class description for
public void prepareEntityForRegistration(EOEntity eoentity)
eoentity
- to be prepared for registrationprotected void handleOptionalRelationshipError(EOEntity eoentity, EORelationship relationship, EOAttribute attribute)
protected void handleMandatoryRelationshipError(EOEntity eoentity, EORelationship relationship, EOAttribute attribute)
public void checkForeignKeys(EOEntity eoentity)
NOT NULL
,
but whose relationship is marked as non-mandatory and vice-versa. This
error is not checked by EOModeler, so we do it here.
eoentity
- to be checkpublic void registerDescriptionForEntitiesInModel(EOModel model)
model
- that contains all of the entities to be registerdpublic void registerDescriptionForEntity(EOEntity entity)
newClassDescriptionForEntity
which can be overridden by subclasses to provide a
different class description subclass.
entity
- to register the class description forpublic void registerDescriptionForClass(Class class1)
class1
- class object to have a custom class
description registered for.
|
Last updated: Do, Dez 9, 2004 12:46 PM CET | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |