org.compass.core.mapping
Interface CascadeMapping

All Known Subinterfaces:
InternalCascadeMapping
All Known Implementing Classes:
AbstractRefAliasMapping, ComponentMapping, IdComponentMapping, ParentMapping, PlainCascadeMapping, ReferenceMapping

public interface CascadeMapping

Cascade mappings responsible for getting objects for cascading operations as well as marking which operations are allowed to be cascaded.

Author:
kimchy

Method Summary
 Cascade[] getCascades()
          Returns the cascades of the mapping.
 Object getCascadeValue(Object root)
          Returns the value that should be cascaded basde on the root object.
 boolean shouldCascade(Cascade cascade)
          Returns true if cascading should be performed for the cascade parameter.
 boolean shouldCascadeCreate()
          Returns true if cascading should be performed for create operations.
 boolean shouldCascadeDelete()
          Returns true if cascading should be performed for delete operations.
 boolean shouldCascadeSave()
          Returns true if cascading should be performed for save operations.
 

Method Detail

getCascadeValue

Object getCascadeValue(Object root)
                       throws CompassException
Returns the value that should be cascaded basde on the root object.

Parameters:
root - The root object to extract the cascaded value from
Returns:
The cascaded value to cascade
Throws:
CompassException

getCascades

Cascade[] getCascades()
Returns the cascades of the mapping.


shouldCascadeDelete

boolean shouldCascadeDelete()
Returns true if cascading should be performed for delete operations.


shouldCascadeCreate

boolean shouldCascadeCreate()
Returns true if cascading should be performed for create operations.


shouldCascadeSave

boolean shouldCascadeSave()
Returns true if cascading should be performed for save operations.


shouldCascade

boolean shouldCascade(Cascade cascade)
Returns true if cascading should be performed for the cascade parameter.



Copyright (c) 2004-2009 The Compass Project.