- Author
- Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g
Definition at line 30 of file ViewSets.java.
◆ ViewSets()
org.turro.financials.view.ViewSets.ViewSets |
( |
| ) |
|
Definition at line 34 of file ViewSets.java.
35 groupA =
new HashSet<RegisterView>();
36 groupB =
new HashSet<RegisterView>();
37 groupA.add(ViewWrapper.getFormalView());
◆ getGroupA()
Set<RegisterView> org.turro.financials.view.ViewSets.getGroupA |
( |
| ) |
|
◆ getGroupB()
Set<RegisterView> org.turro.financials.view.ViewSets.getGroupB |
( |
| ) |
|
◆ getSqlWhereA()
String org.turro.financials.view.ViewSets.getSqlWhereA |
( |
String |
field | ) |
|
Definition at line 99 of file ViewSets.java.
100 PhraseBuilder pb =
new PhraseBuilder();
101 if(!groupA.isEmpty()) {
102 pb.addWord(
"and " + field +
" in (");
103 for(RegisterView rv : groupA) {
104 pb.addPendingSeparator(
",");
105 pb.addWord(rv.getId() +
"");
107 pb.cancelSeparator();
110 pb.addWord(
"and 1=2");
112 return pb.toString();
◆ getSqlWhereAB()
String org.turro.financials.view.ViewSets.getSqlWhereAB |
( |
String |
field | ) |
|
Definition at line 75 of file ViewSets.java.
76 PhraseBuilder pb =
new PhraseBuilder();
77 if(!groupA.isEmpty()) {
78 pb.addWord(
"and (" + field +
" in (");
79 for(RegisterView rv : groupA) {
80 pb.addPendingSeparator(
",");
81 pb.addWord(rv.getId() +
"");
85 if(!groupB.isEmpty()) {
86 pb.addWord(
"or " + field +
" in (");
87 for(RegisterView rv : groupB) {
88 pb.addPendingSeparator(
",");
89 pb.addWord(rv.getId() +
"");
◆ getSqlWhereB()
String org.turro.financials.view.ViewSets.getSqlWhereB |
( |
String |
field | ) |
|
Definition at line 115 of file ViewSets.java.
116 PhraseBuilder pb =
new PhraseBuilder();
117 if(!groupB.isEmpty()) {
118 pb.addWord(
"and " + field +
" in (");
119 for(RegisterView rv : groupB) {
120 pb.addPendingSeparator(
",");
121 pb.addWord(rv.getId() +
"");
123 pb.cancelSeparator();
126 pb.addWord(
"and 1=2");
128 return pb.toString();
◆ getStringFilter()
String org.turro.financials.view.ViewSets.getStringFilter |
( |
| ) |
|
Definition at line 58 of file ViewSets.java.
59 PhraseBuilder pb =
new PhraseBuilder();
60 for(RegisterView v : groupA) {
61 pb.addWord(v.getName());
62 pb.addPendingSeparator(
",");
64 if(!groupB.isEmpty()) {
67 for(RegisterView v : groupB) {
68 pb.addWord(v.getName());
69 pb.addPendingSeparator(
",");
◆ setGroupA()
void org.turro.financials.view.ViewSets.setGroupA |
( |
Set< RegisterView > |
groupA | ) |
|
Definition at line 44 of file ViewSets.java.
46 this.groupA.addAll(groupA);
◆ setGroupB()
void org.turro.financials.view.ViewSets.setGroupB |
( |
Set< RegisterView > |
groupB | ) |
|
Definition at line 53 of file ViewSets.java.
55 this.groupB.addAll(groupB);
The documentation for this class was generated from the following file: