KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > versant > core > jdo > sco > VersantSCOCollection


1
2 /*
3  * Copyright (c) 1998 - 2005 Versant Corporation
4  * All rights reserved. This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License v1.0
6  * which accompanies this distribution, and is available at
7  * http://www.eclipse.org/legal/epl-v10.html
8  *
9  * Contributors:
10  * Versant Corporation - initial API and implementation
11  */

12 package com.versant.core.jdo.sco;
13
14 import com.versant.core.jdo.VersantPersistenceManagerImp;
15 import com.versant.core.common.CollectionDiff;
16 import com.versant.core.common.PersistenceContext;
17 import com.versant.core.jdo.VersantPersistenceManagerImp;
18
19 /**
20  * SCO's that are collections must implement this to have efficient database access.
21  * <p/>
22  * SCO collections that do not implement this will be treated like replaced
23  * collections on commit or flush. All the old values will be deleted and all the
24  * current values insert.
25  */

26 public interface VersantSCOCollection extends VersantSimpleSCO {
27
28
29     /**
30      * Called on commit or flush to get changes to this collection.
31      */

32     CollectionDiff getCollectionDiff(PersistenceContext pm);
33
34     /**
35      * Put references to all the values into collectionData. If the
36      * values are PC instances then the instances themselves or their
37      * OIDs may be stored in collectionData.
38      */

39     CollectionData fillCollectionData(CollectionData collectionData);
40
41
42 }
43
Popular Tags