KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > ivata > groupware > container > persistence > listener > RemovePersistenceListener


1 /*
2  * Copyright (c) 2001 - 2005 ivata limited.
3  * All rights reserved.
4  * -----------------------------------------------------------------------------
5  * ivata groupware may be redistributed under the GNU General Public
6  * License as published by the Free Software Foundation;
7  * version 2 of the License.
8  *
9  * These programs are free software; you can redistribute them and/or
10  * modify them under the terms of the GNU General Public License
11  * as published by the Free Software Foundation; version 2 of the License.
12  *
13  * These programs are distributed in the hope that they will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
16  *
17  * See the GNU General Public License in the file LICENSE.txt for more
18  * details.
19  *
20  * If you would like a copy of the GNU General Public License write to
21  *
22  * Free Software Foundation, Inc.
23  * 59 Temple Place - Suite 330
24  * Boston, MA 02111-1307, USA.
25  *
26  *
27  * To arrange commercial support and licensing, contact ivata at
28  * http://www.ivata.com/contact.jsp
29  * -----------------------------------------------------------------------------
30  * $Log: RemovePersistenceListener.java,v $
31  * Revision 1.2 2005/04/09 17:19:38 colinmacleod
32  * Changed copyright text to GPL v2 explicitly.
33  *
34  * Revision 1.1 2005/03/10 19:23:05 colinmacleod
35  * Moved to ivata groupware.
36  *
37  * -----------------------------------------------------------------------------
38  */

39 package com.ivata.groupware.container.persistence.listener;
40
41 import com.ivata.mask.persistence.PersistenceException;
42 import com.ivata.mask.persistence.PersistenceSession;
43 import com.ivata.mask.valueobject.ValueObject;
44
45 /**
46  * Called just before an object is removed from the persistence store.
47  * @since ivata groupware 0.10 (2005-01-17)
48  * @author Colin MacLeod
49  * <a HREF="mailto:colin.macleod@ivata.com">colin.macleod@ivata.com</a>
50  * @version $Revision: 1.2 $
51  */

52 public interface RemovePersistenceListener {
53     /**
54      * Called just before a a value object is removed from the persistence
55      * store.
56      *
57      * @param session
58      * current persistence session. Should have been previously
59      * opened with {@link #openSession() openSession()}.
60      * @param valueObject
61      * object about to be removed
62      * @throws PersistenceException
63      * if the object cannot be removed.
64      */

65     void onRemove(PersistenceSession session, ValueObject valueObject)
66             throws PersistenceException;
67 }
68
Popular Tags