OpenConcerto

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

svn://code.openconcerto.org/openconcerto

Rev

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

Rev Author Line No. Line
19 ilm 1
/*
2
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
3
 *
4
 * Copyright 2011 OpenConcerto, by ILM Informatique. All rights reserved.
5
 *
6
 * The contents of this file are subject to the terms of the GNU General Public License Version 3
7
 * only ("GPL"). You may not use this file except in compliance with the License. You can obtain a
8
 * copy of the License at http://www.gnu.org/licenses/gpl-3.0.html See the License for the specific
9
 * language governing permissions and limitations under the License.
10
 *
11
 * When distributing the software, include this License Header Notice in each file.
12
 */
13
 
14
 package org.openconcerto.sql.model;
15
 
67 ilm 16
import org.openconcerto.sql.model.graph.Link;
17
import org.openconcerto.sql.model.graph.Link.Direction;
18
 
19 ilm 19
import java.util.Collection;
20
import java.util.Map;
21
import java.util.Set;
22
 
23
public class SQLImmutableRowValues extends SQLRowAccessor {
24
 
25
    private final SQLRowValues delegate;
26
 
27
    public SQLImmutableRowValues(SQLRowValues delegate) {
28
        super(delegate.getTable());
29
        this.delegate = delegate;
30
    }
31
 
32
    @Override
33
    public SQLRowValues createEmptyUpdateRow() {
34
        return this.delegate.createEmptyUpdateRow();
35
    }
36
 
37
    @Override
38
    public Collection<SQLRowValues> getReferentRows() {
39
        return this.delegate.getReferentRows();
40
    }
41
 
42
    @Override
43
    public Set<SQLRowValues> getReferentRows(SQLField refField) {
44
        return this.delegate.getReferentRows(refField);
45
    }
46
 
47
    @Override
48
    public Collection<SQLRowValues> getReferentRows(SQLTable refTable) {
49
        return this.delegate.getReferentRows(refTable);
50
    }
51
 
67 ilm 52
    @Override
53
    public Collection<SQLRowValues> followLink(Link l, Direction direction) {
54
        return this.delegate.followLink(l, direction);
55
    }
56
 
19 ilm 57
    public int size() {
58
        return this.delegate.size();
59
    }
60
 
61
    @Override
62
    public final int getID() {
63
        return this.delegate.getID();
64
    }
65
 
66
    @Override
67
    public final Number getIDNumber() {
68
        return this.delegate.getIDNumber();
69
    }
70
 
71
    @Override
72
    public final Object getObject(String fieldName) {
73
        return this.delegate.getObject(fieldName);
74
    }
75
 
76
    @Override
77
    public Map<String, Object> getAbsolutelyAll() {
78
        return this.delegate.getAbsolutelyAll();
79
    }
80
 
81
    @Override
82
    public final SQLRowAccessor getForeign(String fieldName) {
83
        return this.delegate.getForeign(fieldName);
84
    }
85
 
86
    @Override
87
    public boolean isForeignEmpty(String fieldName) {
88
        return this.delegate.isForeignEmpty(fieldName);
89
    }
90
 
80 ilm 91
    @Override
83 ilm 92
    public Number getForeignIDNumber(String fieldName) throws IllegalArgumentException {
93
        return this.delegate.getForeignIDNumber(fieldName);
80 ilm 94
    }
95
 
19 ilm 96
    public boolean isDefault(String fieldName) {
97
        return this.delegate.isDefault(fieldName);
98
    }
99
 
100
    @Override
101
    public Set<String> getFields() {
102
        return this.delegate.getFields();
103
    }
104
 
105
    @Override
106
    public final SQLRow asRow() {
107
        return this.delegate.asRow();
108
    }
109
 
110
    @Override
111
    public final SQLRowValues asRowValues() {
112
        return this.delegate.deepCopy();
113
    }
114
 
115
    public final String printTree() {
116
        return this.delegate.printTree();
117
    }
118
 
119
    public final String printGraph() {
120
        return this.delegate.printGraph();
121
    }
122
 
123
    public final boolean equalsGraph(SQLRowValues other) {
124
        return this.delegate.equalsGraph(other);
125
    }
126
 
127
    @Override
25 ilm 128
    public SQLTableModifiedListener createTableListener(SQLDataListener l) {
19 ilm 129
        return this.delegate.createTableListener(l);
130
    }
131
 
132
    @Override
133
    public boolean equals(Object obj) {
134
        return this.delegate.equals(obj);
135
    }
136
 
137
    @Override
138
    public int hashCode() {
139
        return this.delegate.hashCode();
140
    }
141
 
142
    @Override
143
    public String toString() {
144
        return super.toString() + " on <" + this.delegate.toString() + ">";
145
    }
146
}