Esempio n. 1
0
 protected FilterJoinNode(
     Class joinClass,
     String[] joinColumns,
     String column,
     FilterExpress express,
     Serializable value) {
   Objects.requireNonNull(joinClass);
   Objects.requireNonNull(joinColumns);
   this.joinClass = joinClass;
   this.joinColumns = joinColumns;
   this.column = column;
   this.express = express;
   this.value = value;
 }
Esempio n. 2
0
 @Override
 protected FilterNode any(final FilterNode node0, boolean signor) {
   Objects.requireNonNull(node0);
   if (!(node0 instanceof FilterJoinNode)) {
     throw new IllegalArgumentException(
         this
             + (signor ? " or " : " and ")
             + " a node but "
             + String.valueOf(node0)
             + "is not a "
             + FilterJoinNode.class.getSimpleName());
   }
   final FilterJoinNode node = (FilterJoinNode) node0;
   if (this.nodes == null) {
     this.nodes = new FilterNode[] {node};
     this.or = signor;
     return this;
   }
   if (or == signor || this.column == null) {
     FilterNode[] newsiblings = new FilterNode[nodes.length + 1];
     System.arraycopy(nodes, 0, newsiblings, 0, nodes.length);
     newsiblings[nodes.length] = node;
     this.nodes = newsiblings;
     if (this.column == null) this.or = signor;
     return this;
   }
   this.nodes = new FilterNode[] {new FilterJoinNode(node), node};
   this.column = null;
   this.express = null;
   this.value = null;
   this.joinClass = null;
   this.joinEntity = null;
   this.joinColumns = null;
   this.or = signor;
   return this;
 }