FileDocCategorySizeDatePackage
DeleteEvent.javaAPI DocHibernate 3.2.51391Mon Jul 11 15:34:00 BST 2005org.hibernate.event

DeleteEvent

public class DeleteEvent extends AbstractEvent
Defines an event class for the deletion of an entity.
author
Steve Ebersole

Fields Summary
private Object
object
private String
entityName
private boolean
cascadeDeleteEnabled
Constructors Summary
public DeleteEvent(Object object, EventSource source)
Constructs a new DeleteEvent instance.

param
object The entity to be deleted.
param
source The session from which the delete event was generated.

		super(source);
		if (object == null) {
			throw new IllegalArgumentException(
					"attempt to create delete event with null entity"
				);
		}
		this.object = object;
	
public DeleteEvent(String entityName, Object object, EventSource source)

		this(object, source);
		this.entityName = entityName;
	
public DeleteEvent(String entityName, Object object, boolean isCascadeDeleteEnabled, EventSource source)

		this(object, source);
		this.entityName = entityName;
		cascadeDeleteEnabled = isCascadeDeleteEnabled;
	
Methods Summary
public java.lang.StringgetEntityName()

		return entityName;
	
public java.lang.ObjectgetObject()
Returns the encapsulated entity to be deleed.

return
The entity to be deleted.

		return object;
	
public booleanisCascadeDeleteEnabled()

		return cascadeDeleteEnabled;