View Javadoc

1   /*
2    * Copyright 2004-2006 the Seasar Foundation and the Others.
3    *
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    *     http://www.apache.org/licenses/LICENSE-2.0
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, 
13   * either express or implied. See the License for the specific language
14   * governing permissions and limitations under the License.
15   */
16  package org.seasar.tuigwaa.model.common;
17  
18  import java.util.Map;
19  
20  import org.seasar.tuigwaa.database.DataTable;
21  import org.seasar.tuigwaa.database.function.DaoMethod;
22  
23  
24  public interface EntityDAO {
25  
26  	public static final String LIST = "list";
27  
28  	public static final String LOAD = "load";
29  
30  	public static final String DELETE = "delete";
31  
32  	public static final String DELETEALL = "deleteAll";
33  
34  	public static final String ORDERED_LIST = "orderList";
35  
36  	public static final String SAVEUPDATE = "saveOrUpdate";
37  
38  	public static final String INJECT_CRITERIA = "injectCriteria";
39  
40  	public DaoMethod getMethod(String methodName);
41  
42  	public Object load(Long id);
43  
44  	public Object loadByValue(String attrName, Object value);
45  
46  	public void delete(Long id);
47  
48  	public void deleteAll();
49  
50  	public void saveOrUpdate(Object obj);
51  
52  	public Object getValue(String name);
53  
54  	public DataTable list();
55  	
56  	public DataTable find(Map filterMap);
57  }