OpenConcerto

Dépôt officiel du code source de l'ERP OpenConcerto
sonarqube

svn://code.openconcerto.org/openconcerto

Rev

Rev 86 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
74 ilm 1
package org.openconcerto.modules.extensionbuilder.list;
2
 
3
import java.util.ArrayList;
4
import java.util.List;
5
 
6
public class ListDescriptor {
7
 
8
    private final List<ColumnDescriptor> columns = new ArrayList<ColumnDescriptor>();
9
    private String id;
10
 
11
    private String mainTable;
12
 
13
    public ListDescriptor(String id) {
14
        this.id = id;
15
    }
16
 
17
    public String getId() {
181 ilm 18
        return this.id;
74 ilm 19
    }
20
 
21
    public void setId(String id) {
22
        this.id = id;
23
    }
24
 
25
    public void setMainTable(String mainTable) {
26
        this.mainTable = mainTable;
27
    }
28
 
29
    public String getMainTable() {
181 ilm 30
        return this.mainTable;
74 ilm 31
    }
32
 
33
    public List<ColumnDescriptor> getColumns() {
181 ilm 34
        return this.columns;
74 ilm 35
    }
36
 
37
    @Override
38
    public String toString() {
39
        return this.id;
40
    }
41
 
42
    public void add(ColumnDescriptor f) {
43
        this.columns.add(f);
44
 
45
    }
46
 
47
    public int getColumnCount() {
48
        return this.columns.size();
49
    }
86 ilm 50
 
51
    public void removeAllColumns() {
52
        this.columns.clear();
53
    }
181 ilm 54
 
55
    public void remove(ColumnDescriptor c) {
56
        this.columns.remove(c);
57
    }
74 ilm 58
}