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.database;
17  
18  import java.util.Collection;
19  import java.util.Iterator;
20  import java.util.List;
21  import java.util.Map;
22  
23  /***
24   * Tuigwaaの仮想のテーブルを表す
25   * IDについては、対応する実テーブルとカラム名が一致するとは限らない
26   * 
27   * @author nishioka
28   */
29  public interface DataTable extends Iterator {
30  
31  	public static final int BEAN_DATA = 0;
32  
33  	public static final int PRIMITIVE_DATA = 1;
34  
35  	public void setFilterMap(Map filterMap);
36  
37  	public String getName();
38  
39  	public String getHeader(int index);
40  
41  	public String getHeader();
42  	
43  	public List getHeaders();
44  
45  	public Map getDisplayHeaderMap();
46  
47  	public Iterator getHeaderIterator();
48  
49  	public int getRowSize();
50  
51  	public int getColumnSize();
52  
53  	public Collection getDataList();
54  
55  	public Object getData();
56  
57  	public Object getData(int columnIndex);
58  
59  	public Object getData(String columnName);
60  
61  	public Object getData(int row, String columnName);
62  
63  	public Object getData(int row, int column);
64  
65  	public Object getRowObject();
66  
67  	public Object getRowObject(int row);
68  
69  	public Map getDataMap(int row);
70  
71  	public boolean hasNext();
72  
73  	public boolean hasNextRow();
74  
75  	public boolean hasNextColumn();
76  
77  	public boolean hasNextColumn(int index);
78  
79  	public Object next();
80  
81  	public DataRow nextRow();
82  
83  	public Object nextColumn();
84  
85  	public void remove();
86  
87  	public boolean isSpreadSheet();
88  
89  	public void init();
90  
91  	public void initCurrentColumn();
92  
93  	public void initCurrentRow();
94  
95  	public int getCurrentColumn();
96  
97  	public int getCurrentRow();
98  
99  	public void incrementCurrentRow();
100 
101 	public void incrementCurrentColumn();
102 
103 	public void decrementCurrentRow();
104 
105 	public void decrementCurrentColumn();
106 
107 	public boolean lastRow();
108 	
109 	public boolean lastColumn();
110 	
111 }