View Javadoc

1   package br.com.caelum.seleniumdsl.table.layout;
2   
3   import br.com.caelum.seleniumdsl.table.Table;
4   
5   public interface TableLayout {
6   	/**
7   	 * @param col
8   	 *            the column index
9   	 * @return the text of the column
10  	 */
11  	public String headerValue(int col);
12  
13  	/**
14  	 * Used when the header's text is a link. Common when doing pagination
15  	 * 
16  	 * @param col
17  	 *            the column index
18  	 * @return the '<a href' tag's text
19  	 */
20  	public String headerLinkValue(int col);
21  
22  	/**
23  	 * @return The tbody rows. Some layouts will remove the first row and return all the others, ignoring if the last row is a footer or no.
24  	 */
25  	public int getContentCount();
26  
27  	/**
28  	 * @param row
29  	 *            the row index
30  	 * @param col
31  	 *            the col index
32  	 * @return the text of the cell or null if the cell is not found
33  	 */
34  	public String value(int row, int col);
35  
36  	/**
37  	 * @return The number of columns on the header.
38  	 */
39  	public int getColCount();
40  
41  	/**
42  	 * @return The full row count, including possible header and footer.
43  	 */
44  	public int getRowCount();
45  
46  	/**
47  	 * @param col
48  	 *            the header text of the column
49  	 * @param content
50  	 *            the content to search
51  	 * @return true if the content exists
52  	 */
53  	public boolean contains(Table table, String col, String content);
54  }