ea30d0163332aa2663bed7e4de0f65f957826823
[jalview.git] / src / jalview / fts / api / FTSDataColumnI.java
1 /*
2  * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
3  * Copyright (C) $$Year-Rel$$ The Jalview Authors
4  * 
5  * This file is part of Jalview.
6  * 
7  * Jalview is free software: you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License 
9  * as published by the Free Software Foundation, either version 3
10  * of the License, or (at your option) any later version.
11  *  
12  * Jalview is distributed in the hope that it will be useful, but 
13  * WITHOUT ANY WARRANTY; without even the implied warranty 
14  * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
15  * PURPOSE.  See the GNU General Public License for more details.
16  * 
17  * You should have received a copy of the GNU General Public License
18  * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
19  * The Jalview Authors are detailed in the 'AUTHORS' file.
20  */
21
22 package jalview.fts.api;
23
24 /**
25  * This interface provides a model for the dynamic data column configuration
26  * 
27  * @author tcnofoegbu
28  *
29  */
30 public interface FTSDataColumnI
31 {
32   /**
33    * Returns the name of the data column
34    * 
35    * @return the data column's name
36    */
37   public String getName();
38
39   /**
40    * Returns the code of the data column
41    * 
42    * @return the data column's code
43    */
44   public String getCode();
45
46   /**
47    * Returns the minimum width of the data column
48    * 
49    * @return the data column's minimum width
50    */
51   public int getMinWidth();
52
53   /**
54    * Returns the maximum width of the data column
55    * 
56    * @return the data column's maximum width
57    */
58   public int getMaxWidth();
59
60   /**
61    * Returns the preferred width of the data column
62    * 
63    * @return the data column's preferred width
64    */
65   public int getPreferredWidth();
66
67   /**
68    * Determines if the data column is the primary key column
69    * 
70    * @return true if data column is the primary key column, otherwise false
71    */
72   public boolean isPrimaryKeyColumn();
73
74   /**
75    * Checks if the data column field can be used to perform a search query
76    * 
77    * @return true means the data column is searchable
78    */
79   public boolean isSearchable();
80
81   /**
82    * Checks if the data column is displayed by default
83    * 
84    * @return true means the data column is shown by default
85    */
86   public boolean isVisibleByDefault();
87
88   /**
89    * Returns the data column's data type class
90    * 
91    * @return the Class for the data column's data type
92    */
93   public Class getDataColumnClass();
94
95   /**
96    * Returns the data colum's FTS data column group
97    * 
98    * @return the FTSDataColumnGroupI for the column
99    */
100   public FTSDataColumnGroupI getGroup();
101
102   /**
103    * This interface provides a model for the dynamic data column group
104    * 
105    */
106   public interface FTSDataColumnGroupI
107   {
108     /**
109      * Returns the Id of the data column's group
110      * 
111      * @return the data column's group Id
112      */
113     public String getID();
114
115     /**
116      * Returns the name of the group
117      * 
118      * @return the group's name
119      */
120     public String getName();
121
122     /**
123      * Returns the sort order of the group
124      * 
125      * @return the group's sort order
126      */
127     public int getSortOrder();
128   }
129 }