er.extensions.partials
Class ERXPartialGenericRecord
java.lang.Object
com.webobjects.eocontrol.EOCustomObject
com.webobjects.eocontrol.EOGenericRecord
er.extensions.eof.ERXGenericRecord
er.extensions.partials.ERXPartialGenericRecord
- All Implemented Interfaces:
- _EOPrivateMemento, EODeferredFaulting, EOEnterpriseObject, EOFaulting, EOKeyValueCoding, EOKeyValueCoding._BestBindingCreation._ForwardingBindingCheck, EOKeyValueCoding._KeyBindingCreation, EOKeyValueCodingAdditions, EORelationshipManipulation, EOValidation, NSKeyValueCoding, NSKeyValueCoding._KeyBindingCreation, NSKeyValueCoding._ReflectionKeyBindingCreation.Callback, NSKeyValueCoding.ErrorHandling, NSKeyValueCodingAdditions, NSValidation, ERXDatabaseContextDelegate.AutoBatchFaultingEnterpriseObject, ERXEnterpriseObject, ERXGeneratesPrimaryKeyInterface, ERXGuardedObjectInterface, ERXKey.ValueCoding, Serializable
public class ERXPartialGenericRecord
- extends ERXGenericRecord
For overview information on partials, read the package.html in er.extensions.partials.
ERXPartialGenericRecord is the base class of any entity that allows itself to be extended
with partials.
- See Also:
- Serialized Form
- Author:
- mschrag
| Nested classes/interfaces inherited from interface com.webobjects.foundation.NSKeyValueCoding |
NSKeyValueCoding._BooleanFieldBinding, NSKeyValueCoding._BooleanMethodBinding, NSKeyValueCoding._FieldBinding, NSKeyValueCoding._ForwardingBinding, NSKeyValueCoding._KeyBinding, NSKeyValueCoding._NumberFieldBinding, NSKeyValueCoding._NumberMethodBinding, NSKeyValueCoding._ReflectionKeyBindingCreation, NSKeyValueCoding.ErrorHandling, NSKeyValueCoding.Null, NSKeyValueCoding.UnknownKeyException, NSKeyValueCoding.ValueAccessor |
| Nested classes/interfaces inherited from interface com.webobjects.foundation.NSKeyValueCoding |
NSKeyValueCoding._BooleanFieldBinding, NSKeyValueCoding._BooleanMethodBinding, NSKeyValueCoding._FieldBinding, NSKeyValueCoding._ForwardingBinding, NSKeyValueCoding._KeyBinding, NSKeyValueCoding._NumberFieldBinding, NSKeyValueCoding._NumberMethodBinding, NSKeyValueCoding._ReflectionKeyBindingCreation, NSKeyValueCoding.ErrorHandling, NSKeyValueCoding.Null, NSKeyValueCoding.UnknownKeyException, NSKeyValueCoding.ValueAccessor |
| Nested classes/interfaces inherited from interface com.webobjects.foundation.NSKeyValueCoding |
NSKeyValueCoding._BooleanFieldBinding, NSKeyValueCoding._BooleanMethodBinding, NSKeyValueCoding._FieldBinding, NSKeyValueCoding._ForwardingBinding, NSKeyValueCoding._KeyBinding, NSKeyValueCoding._NumberFieldBinding, NSKeyValueCoding._NumberMethodBinding, NSKeyValueCoding._ReflectionKeyBindingCreation, NSKeyValueCoding.ErrorHandling, NSKeyValueCoding.Null, NSKeyValueCoding.UnknownKeyException, NSKeyValueCoding.ValueAccessor |
| Nested classes/interfaces inherited from interface com.webobjects.foundation.NSKeyValueCoding |
NSKeyValueCoding._BooleanFieldBinding, NSKeyValueCoding._BooleanMethodBinding, NSKeyValueCoding._FieldBinding, NSKeyValueCoding._ForwardingBinding, NSKeyValueCoding._KeyBinding, NSKeyValueCoding._NumberFieldBinding, NSKeyValueCoding._NumberMethodBinding, NSKeyValueCoding._ReflectionKeyBindingCreation, NSKeyValueCoding.ErrorHandling, NSKeyValueCoding.Null, NSKeyValueCoding.UnknownKeyException, NSKeyValueCoding.ValueAccessor |
| Fields inherited from interface er.extensions.eof.ERXEnterpriseObject |
applyRestrictingQualifierOnInsert, DidDeleteProcessor, DidInsertProcessor, DidRevertProcessor, DidUpdateProcessor, FlushCachesProcessor, insertionTrackingLog, KEY_MARKER, log, logMod, tranLogDidDelete, tranLogDidInsert, tranLogDidRevert, tranLogDidUpdate, tranLogMightDelete, tranLogWillDelete, tranLogWillInsert, tranLogWillRevert, tranLogWillUpdate, validation, validationException, WillDeleteProcessor, WillInsertProcessor, WillRevertProcessor, WillUpdateProcessor |
| Methods inherited from class er.extensions.eof.ERXGenericRecord |
_otherStorageBinding, _setPrimaryKeyDictionary, _setUpdateInverseRelationships, _setValueForPrimaryKey, _updateInverseRelationships, addObjectsToBothSidesOfRelationshipWithKey, addObjectToBothSidesOfRelationshipWithKey, applyRestrictingQualifierOnInsert, awakeFromClientUpdate, batchCheckConsistency, batchFaultingRelationshipName, batchFaultingSourceGlobalID, batchFaultingTimeStamp, canDelete, canUpdate, changesFromCommittedSnapshot, checkConsistency, checkMatchingEditingContexts, clearProperties, committedSnapshot, committedSnapshotValueForKey, description, didCopyFromChildInEditingContext, encryptedPrimaryKey, entity, excludeObjectFromPropertyWithKey, flushCaches, foreignKeyForRelationshipWithKey, getClassLog, hasKeyChangedFromCommittedSnapshot, hasKeyChangedFromCommittedSnapshotFromValue, hasKeyChangedFromCommittedSnapshotFromValueToNewValue, hasKeyChangedFromCommittedSnapshotToValue, includeObjectIntoPropertyWithKey, init, isDeletedEO, isNewEO, isNewObject, isUpdatedObject, isValidatedWhenNested, localesForKey, localInstanceIn, localInstanceOf, localInstancesOf, localizationShouldFallbackToDefaultLanguage, parentObjectStoreIsObjectStoreCoordinator, permanentGlobalID, permanentGlobalID, primaryKey, primaryKeyAttributeNames, primaryKeyDictionary, primaryKeyInTransaction, rawPrimaryKey, rawPrimaryKeyInTransaction, refetchObjectFromDB, refetchObjectFromDBinEditingContext, removeObjectsFromBothSidesOfRelationshipWithKey, removeObjectsFromPropertyWithKey, self, setBatchFaultingTimestamp, setValidatedWhenNested, shouldTrimSpaces, takeStoredValueForKey, takeValueForKey, takeValueForKey, toLongString, toString, touchFromBatchFaultingSource, trimSpaces, updateFromSnapshot, validateValueForKey, valueForKey, willReadRelationship |
| Methods inherited from class com.webobjects.eocontrol.EOCustomObject |
__classDescription, __clearPendingChanges, __editingContext, __globalID, __hasAuxillaryObservers, __hasPendingChanges, __hasPendingUpdate, __isInitialized, __isPendingDeletion, __isPendingInsertion, __isShared, __lastSnapshot, __originalSnapshot, __retainCount, __setAuxillaryObservers, __setEditingContext, __setGlobalID, __setInitialized, __setLastSnapshot, __setOriginalSnapshot, __setPendingDeletion, __setPendingInsertion, __setPendingUpdate, __setRetainCount, __setShared, _createKeyGetBindingForKey, _createKeySetBindingForKey, _createStoredKeyGetBindingForKey, _createStoredKeySetBindingForKey, _fieldKeyBinding, _forwardingBindingNeededForClass, _methodKeyGetBinding, _methodKeySetBinding, addObjectToPropertyWithKey, allPropertyKeys, attributeKeys, canAccessFieldsDirectly, changesFromSnapshot, classDescriptionForDestinationKey, clearFault, deleteRuleForRelationshipKey, editingContext, entityName, eoDescription, eoShallowDescription, equals, faultHandler, handleQueryWithUnboundKey, handleTakeValueForUnboundKey, hashCode, inverseForRelationshipKey, invokeRemoteMethod, isFault, isToManyKey, opaqueState, ownsDestinationObjectsForRelationshipKey, prepareValuesForClient, propagateDeleteWithEditingContext, readResolve, reapplyChangesFromDictionary, removeObjectFromBothSidesOfRelationshipWithKey, removeObjectFromPropertyWithKey, shouldUseStoredAccessors, snapshot, storedValueForKey, takeValueForKeyPath, takeValuesFromDictionary, takeValuesFromDictionaryWithMapping, toManyRelationshipKeys, toOneRelationshipKeys, turnIntoFault, unableToSetNullForKey, userPresentableDescription, validateClientUpdate, validateForDelete, valueForKeyPath, valuesForKeys, valuesForKeysWithMapping, willChange, willRead |
| Methods inherited from interface com.webobjects.eocontrol.EOEnterpriseObject |
allPropertyKeys, attributeKeys, changesFromSnapshot, classDescription, classDescriptionForDestinationKey, deleteRuleForRelationshipKey, editingContext, entityName, eoDescription, eoShallowDescription, inverseForRelationshipKey, invokeRemoteMethod, isToManyKey, opaqueState, ownsDestinationObjectsForRelationshipKey, prepareValuesForClient, propagateDeleteWithEditingContext, reapplyChangesFromDictionary, snapshot, toManyRelationshipKeys, toOneRelationshipKeys, userPresentableDescription, willChange |
| Methods inherited from interface com.webobjects.eocontrol.EOEnterpriseObject |
allPropertyKeys, attributeKeys, changesFromSnapshot, classDescription, classDescriptionForDestinationKey, deleteRuleForRelationshipKey, editingContext, entityName, eoDescription, eoShallowDescription, inverseForRelationshipKey, invokeRemoteMethod, isToManyKey, opaqueState, ownsDestinationObjectsForRelationshipKey, prepareValuesForClient, propagateDeleteWithEditingContext, reapplyChangesFromDictionary, snapshot, toManyRelationshipKeys, toOneRelationshipKeys, userPresentableDescription, willChange |
ERXPartialGenericRecord
public ERXPartialGenericRecord()
_partialsDictionary
public NSDictionary<Class,ERXPartial> _partialsDictionary()
_partials
public Collection<ERXPartial> _partials()
partialForClass
public <U extends ERXPartial> U partialForClass(Class<U> partialClass)
- Returns the ERXPartial partial implementation for the given partial type.
- Type Parameters:
U - the partial type- Parameters:
partialClass - the partial type
- Returns:
- an instance of the given partial associated with this EO
valueForKey
public Object valueForKey(String key)
- Specified by:
valueForKey in interface NSKeyValueCoding- Overrides:
valueForKey in class EOCustomObject
delete
public void delete()
- Description copied from class:
ERXGenericRecord
- Implementation of
ERXGuardedObjectInterface. This is used to
work around a bug in EOF that doesn't refresh the relationship in the
parent editingContext for the object.
- Specified by:
delete in interface ERXGuardedObjectInterface- Overrides:
delete in class ERXGenericRecord
mightDelete
public void mightDelete()
- Description copied from interface:
ERXEnterpriseObject
- Called as part of the augmented transaction process.
This method is called when deleteObject() is called on
the editing context. The benefit over willDelete() is that in this
method, the relationships are still intact. Mostly, at least,
as it's also called when the deletes cascade.
- Specified by:
mightDelete in interface ERXEnterpriseObject- Overrides:
mightDelete in class ERXGenericRecord
willDelete
public void willDelete()
throws NSValidation.ValidationException
- Description copied from interface:
ERXEnterpriseObject
- Called as part of the augmented transaction process.
This method is called after saveChanges is called on
the editing context, but before the object is actually
deleted from the database. This method is also called
before
validateForDelete is called on this
object. This method is called by the editing context
delegate ERXDefaultEditingContextDelegate.
- Specified by:
willDelete in interface ERXEnterpriseObject- Overrides:
willDelete in class ERXGenericRecord
- Throws:
NSValidation.ValidationException - to stop the object
from being deleted.
willInsert
public void willInsert()
- Description copied from interface:
ERXEnterpriseObject
- Called as part of the augmented transaction process.
This method is called after saveChanges is called on
the editing context, but before the object is actually
inserted into the database. This method is also called
before
validateForInsert is called on this
object. This method is called by the editing context
delegate ERXDefaultEditingContextDelegate.
- Specified by:
willInsert in interface ERXEnterpriseObject- Overrides:
willInsert in class ERXGenericRecord
willUpdate
public void willUpdate()
- Description copied from interface:
ERXEnterpriseObject
- Called as part of the augmented transaction process.
This method is called after saveChanges is called on
the editing context, but before the object is actually
updated in the database. This method is also called
before
validateForSave is called on this
object. This method is called by the editing context
delegate ERXDefaultEditingContextDelegate.
- Specified by:
willUpdate in interface ERXEnterpriseObject- Overrides:
willUpdate in class ERXGenericRecord
didDelete
public void didDelete(EOEditingContext ec)
- Description copied from interface:
ERXEnterpriseObject
- Called on the object after is has been deleted.
The editing context is passed to the object since
by this point the editingContext of the object is
null. You should check if the
ec
is a child context when doing something here that
can't be undone.
- Specified by:
didDelete in interface ERXEnterpriseObject- Overrides:
didDelete in class ERXGenericRecord
- Parameters:
ec - editing context that used to be associated
with the object.
didUpdate
public void didUpdate()
- Description copied from interface:
ERXEnterpriseObject
- Called on the object after is has successfully
been updated in the database.
- Specified by:
didUpdate in interface ERXEnterpriseObject- Overrides:
didUpdate in class ERXGenericRecord
didInsert
public void didInsert()
- Description copied from interface:
ERXEnterpriseObject
- Called on the object after is has successfully
been inserted into the database.
- Specified by:
didInsert in interface ERXEnterpriseObject- Overrides:
didInsert in class ERXGenericRecord
willRevert
public void willRevert()
- Description copied from interface:
ERXEnterpriseObject
- Called on the object before it will be reverted.
Default implementation does nothing other than log.
- Specified by:
willRevert in interface ERXEnterpriseObject- Overrides:
willRevert in class ERXGenericRecord
didRevert
public void didRevert(EOEditingContext ec)
- Description copied from interface:
ERXEnterpriseObject
- Called on the object after it has been reverted.
The editing context is passed to the object because
if the object was in the insertedObjects list before
the revert, the object has had its editingContext
nulled.
Default implementation calls
flushCaches.
- Specified by:
didRevert in interface ERXEnterpriseObject- Overrides:
didRevert in class ERXGenericRecord
- Parameters:
ec - editing context that is either currently associated
with the object if the object was marked as changed or deleted before
the revert, otherwise the editing context that was associated with the object
before the revert.
awakeFromInsertion
public void awakeFromInsertion(EOEditingContext editingContext)
- Description copied from class:
ERXGenericRecord
- Checks the editing context delegate before calling super's
implementation. See the method
_checkEditingContextDelegate
for an explanation as to what this check does.
- Specified by:
awakeFromInsertion in interface EOEnterpriseObject- Overrides:
awakeFromInsertion in class ERXGenericRecord
- Parameters:
editingContext - to be checked to make sure it has the correct type of delegate
set.
awakeFromFetch
public void awakeFromFetch(EOEditingContext editingContext)
- Description copied from class:
ERXGenericRecord
- Checks the editing context delegate before calling super's
implementation. See the method
_checkEditingContextDelegate
for an explanation as to what this check does.
- Specified by:
awakeFromFetch in interface EOEnterpriseObject- Overrides:
awakeFromFetch in class ERXGenericRecord
- Parameters:
editingContext - to be checked to make sure it has the correct type of delegate
set.
_validateValueForKey
protected Object _validateValueForKey(Object value,
String key)
throws NSValidation.ValidationException
- Overrides:
_validateValueForKey in class ERXGenericRecord
- Throws:
NSValidation.ValidationException
validateTakeValueForKeyPath
public Object validateTakeValueForKeyPath(Object value,
String keyPath)
throws NSValidation.ValidationException
- Specified by:
validateTakeValueForKeyPath in interface NSValidation- Overrides:
validateTakeValueForKeyPath in class EOCustomObject
- Throws:
NSValidation.ValidationException
validateForSave
public void validateForSave()
throws NSValidation.ValidationException
- Description copied from class:
ERXGenericRecord
- This method performs a few checks before invoking super's implementation.
If the property key: ERDebuggingEnabled is set to true then the
method
checkConsistency will be called on this object.
- Specified by:
validateForSave in interface EOValidation- Overrides:
validateForSave in class ERXGenericRecord
- Throws:
NSValidation.ValidationException - if the object does not pass validation for saving to the
database.
validateForInsert
public void validateForInsert()
throws NSValidation.ValidationException
- Description copied from class:
ERXGenericRecord
- Calls up validateForInsert() on the class description if it supports it.
- Specified by:
validateForInsert in interface EOValidation- Overrides:
validateForInsert in class ERXGenericRecord
- Throws:
NSValidation.ValidationException - if the object does not pass validation for saving to the
database.
validateForUpdate
public void validateForUpdate()
throws NSValidation.ValidationException
- Description copied from class:
ERXGenericRecord
- Calls up validateForUpdate() on the class description if it supports it.
- Specified by:
validateForUpdate in interface EOValidation- Overrides:
validateForUpdate in class ERXGenericRecord
- Throws:
NSValidation.ValidationException - if the object does not pass validation for saving to the
database.
Copyright © 2002 – 2007 Project Wonder.