com.arsdigita.domain
Interface DomainObjectTraversalAdapter

All Known Implementing Classes:
SimpleDomainObjectTraversalAdapter

public interface DomainObjectTraversalAdapter

This interface is used to control traversal of domain objects. Whenever a property is encountered, the processProperty(com.arsdigita.domain.DomainObject, java.lang.String, com.arsdigita.persistence.metadata.Property, java.lang.String) method will be called to determine whether or not to continue processing the object. The most important use for this is to prevent the needless (and potentially infinite) traversal of associations between objects, but it can also be used to filter out certain attributes.

Instances of this class need to be registered using the DomainObjectTraversal.registerAdapter method.

Version:
$Id: //core-platform/dev/src/com/arsdigita/domain/DomainObjectTraversalAdapter.java#5 $
See Also:
DomainObjectTraversal, SimpleDomainObjectTraversalAdapter

Method Summary
 boolean processProperty(DomainObject obj, String path, Property prop, String context)
          Invoked to determine whether to process a property.
 

Method Detail

processProperty

public boolean processProperty(DomainObject obj,
                               String path,
                               Property prop,
                               String context)
Invoked to determine whether to process a property. Should return true to allow processing to commence, false to prevent it.

Parameters:
obj - the domain object currently being processed
path - the path to the current domain object from the root object being traversed
prop - the property about to be processed
context - the context in which the object is traversed
Returns:
true if the property should be processed


Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 21 2004:2337 UTC