Projekt

Obecné

Profil

Stáhnout (1.16 KB) Statistiky
| Větev: | Revize:
1
package vldc.aswi.model.table.contingencyTable;
2

    
3
/**
4
 * Class representing one cell in Contingency table row.
5
 */
6
public class ContingencyTableRowCell {
7

    
8
    /** Colspan of current cell. */
9
    private int colSpan;
10

    
11
    /** Value in current cell. */
12
    private String value;
13

    
14
    /**
15
     * Constructor.
16
     * @param value - Value in current cell.
17
     * @param colSpan - Colspan of current cell.
18
     */
19
    public ContingencyTableRowCell(String value, int colSpan) {
20
        this.value = value;
21
        this.colSpan = colSpan;
22
    }
23

    
24
    /**
25
     * Get value of current cell.
26
     * @return Value of cell.
27
     */
28
    public String getValue() {
29
        return value;
30
    }
31

    
32
    /**
33
     * Get colspan of current cell.
34
     * @return Colspan of cell.
35
     */
36
    public int getColSpan() {
37
        return colSpan;
38
    }
39

    
40
    /**
41
     * Overrided toString method for debugging.
42
     * @return String.
43
     */
44
    @Override
45
    public String toString() {
46
        return "(" + value + ", " + colSpan + ")";
47
    }
48

    
49
    /**
50
     * Sets the colspan of a cell.
51
     * @param colSpan Colspan of a cell.
52
     */
53
    public void setColSpan(int colSpan) {
54
        this.colSpan = colSpan;
55
    }
56
}
(2-2/2)