Changeset 7163 for FCSSimpleEndpoint
- Timestamp:
- 01/17/18 15:45:23 (6 years ago)
- Location:
- FCSSimpleEndpoint/trunk/src/main/java/eu/clarin/sru/server/fcs/parser
- Files:
-
- 1 deleted
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
FCSSimpleEndpoint/trunk/src/main/java/eu/clarin/sru/server/fcs/parser/QueryGroup.java
r7159 r7163 83 83 if (minOccurs != 1) { 84 84 sb.append("@min="); 85 if (minOccurs == Constants.OCCURS_UNBOUNDED) {85 if (minOccurs == QueryNode.OCCURS_UNBOUNDED) { 86 86 sb.append("*"); 87 87 } else { … … 92 92 if (maxOccurs != 1) { 93 93 sb.append("@max="); 94 if (maxOccurs == Constants.OCCURS_UNBOUNDED) {94 if (maxOccurs == QueryNode.OCCURS_UNBOUNDED) { 95 95 sb.append("*"); 96 96 } else { -
FCSSimpleEndpoint/trunk/src/main/java/eu/clarin/sru/server/fcs/parser/QueryNode.java
r7162 r7163 26 26 */ 27 27 public abstract class QueryNode { 28 /** 29 * Atom occurrence it not bound. 30 */ 31 public static final int OCCURS_UNBOUNDED = -1; 28 32 protected final QueryNodeType nodeType; 29 33 protected final List<QueryNode> children; -
FCSSimpleEndpoint/trunk/src/main/java/eu/clarin/sru/server/fcs/parser/QueryParser.java
r7091 r7163 70 70 public class QueryParser { 71 71 private static final int[] REP_ZERO_OR_MORE = 72 new int[] { 0, Constants.OCCURS_UNBOUNDED };72 new int[] { 0, QueryNode.OCCURS_UNBOUNDED }; 73 73 private static final int[] REP_ONE_OR_MORE = 74 new int[] { 1, Constants.OCCURS_UNBOUNDED };74 new int[] { 1, QueryNode.OCCURS_UNBOUNDED }; 75 75 private static final int[] REP_ZERO_OR_ONE = 76 76 new int[] { 0, 1 }; … … 728 728 int int2Idx = getChildIndex(ctx, FCSParser.INTEGER, int1Idx + 1); 729 729 int min = 0; 730 int max = Constants.OCCURS_UNBOUNDED;730 int max = QueryNode.OCCURS_UNBOUNDED; 731 731 if (commaIdx != -1) { 732 732 if (int1Idx < commaIdx) { … … 745 745 max = min; 746 746 } 747 if ((max != Constants.OCCURS_UNBOUNDED) && (min > max)) {747 if ((max != QueryNode.OCCURS_UNBOUNDED) && (min > max)) { 748 748 throw new ExpressionTreeBuilderException( 749 749 "bad qualifier: min > max (" + min + " > " + max + ")"); -
FCSSimpleEndpoint/trunk/src/main/java/eu/clarin/sru/server/fcs/parser/QuerySegment.java
r7159 r7163 83 83 if (minOccurs != 1) { 84 84 sb.append("@min="); 85 if (minOccurs == Constants.OCCURS_UNBOUNDED) {85 if (minOccurs == QueryNode.OCCURS_UNBOUNDED) { 86 86 sb.append("*"); 87 87 } else { … … 92 92 if (maxOccurs != 1) { 93 93 sb.append("@max="); 94 if (maxOccurs == Constants.OCCURS_UNBOUNDED) {94 if (maxOccurs == QueryNode.OCCURS_UNBOUNDED) { 95 95 sb.append("*"); 96 96 } else {
Note: See TracChangeset
for help on using the changeset viewer.