FileDocCategorySizeDatePackage
FlushVisitor.javaAPI DocHibernate 3.2.51198Thu May 26 22:54:08 BST 2005org.hibernate.event.def

FlushVisitor

public class FlushVisitor extends AbstractVisitor
Process collections reachable from an entity. This visitor assumes that wrap was already performed for the entity.
author
Gavin King

Fields Summary
private Object
owner
Constructors Summary
FlushVisitor(org.hibernate.event.EventSource session, Object owner)

		super(session);
		this.owner = owner;
	
Methods Summary
java.lang.ObjectprocessCollection(java.lang.Object collection, org.hibernate.type.CollectionType type)

		
		if (collection==CollectionType.UNFETCHED_COLLECTION) {
			return null;
		}

		if (collection!=null) {
			final PersistentCollection coll;
			if ( type.hasHolder( getSession().getEntityMode() ) ) {
				coll = getSession().getPersistenceContext().getCollectionHolder(collection);
			}
			else {
				coll = (PersistentCollection) collection;
			}

			Collections.processReachableCollection( coll, type, owner, getSession() );
		}

		return null;