KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > slide > store > NodeStore


1 /*
2  * $Header: /home/cvs/jakarta-slide/src/share/org/apache/slide/store/NodeStore.java,v 1.7 2004/07/28 09:34:41 ib Exp $
3  * $Revision: 1.7 $
4  * $Date: 2004/07/28 09:34:41 $
5  *
6  * ====================================================================
7  *
8  * Copyright 1999-2002 The Apache Software Foundation
9  *
10  * Licensed under the Apache License, Version 2.0 (the "License");
11  * you may not use this file except in compliance with the License.
12  * You may obtain a copy of the License at
13  *
14  * http://www.apache.org/licenses/LICENSE-2.0
15  *
16  * Unless required by applicable law or agreed to in writing, software
17  * distributed under the License is distributed on an "AS IS" BASIS,
18  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19  * See the License for the specific language governing permissions and
20  * limitations under the License.
21  *
22  */

23
24 package org.apache.slide.store;
25
26 import org.apache.slide.common.Service;
27 import org.apache.slide.common.ServiceAccessException;
28 import org.apache.slide.common.Uri;
29 import org.apache.slide.structure.ObjectAlreadyExistsException;
30 import org.apache.slide.structure.ObjectNode;
31 import org.apache.slide.structure.ObjectNotFoundException;
32
33 /**
34  * Store for Node objects.
35  *
36  * @version $Revision: 1.7 $
37  */

38 public interface NodeStore extends Service {
39     
40     
41     // ------------------------------------------------------ Interface Methods
42

43     
44     /**
45      * Retrive an object.
46      *
47      * @param uri Uri of the object we want to retrieve
48      * @exception ServiceAccessException Error accessing the Data Source
49      * @exception ObjectNotFoundException The object to retrieve was not found
50      */

51     ObjectNode retrieveObject(Uri uri)
52         throws ServiceAccessException, ObjectNotFoundException;
53     
54     
55     /**
56      * Update an object.
57      *
58      * @param object Object to update
59      * @exception ServiceAccessException Error accessing the Data Source
60      * @exception ObjectNotFoundException The object to update was not found
61      */

62     void storeObject(Uri uri, ObjectNode object)
63         throws ServiceAccessException, ObjectNotFoundException;
64     
65     
66     /**
67      * Create a new object.
68      *
69      * @param object ObjectNode
70      * @param uri Uri of the object we want to create
71      * @exception ServiceAccessException Error accessing the Data Source
72      * @exception ObjectAlreadyExistsException An object already exists
73      * at this Uri
74      */

75     void createObject(Uri uri, ObjectNode object)
76         throws ServiceAccessException, ObjectAlreadyExistsException;
77     
78     
79     /**
80      * Remove an object.
81      *
82      * @param object Object to remove
83      * @exception ServiceAccessException Error accessing the Data Source
84      * @exception ObjectNotFoundException The object to remove was not found
85      */

86     void removeObject(Uri uri, ObjectNode object)
87         throws ServiceAccessException, ObjectNotFoundException;
88     
89     
90 }
91
Popular Tags