/** * Convenience method that creates a selector name object using the supplied string. * * @param name the name of the selector; may not be null * @return the selector name; never null */ protected SelectorName selector( String name ) { return new SelectorName(name.trim()); }
@Override public boolean equals( Object obj ) { if (obj == this) return true; if (obj instanceof DescendantNodeJoinCondition) { DescendantNodeJoinCondition that = (DescendantNodeJoinCondition)obj; if (this.hc != that.hc) return false; if (!this.descendantSelectorName.equals(that.descendantSelectorName)) return false; if (!this.ancestorSelectorName.equals(that.ancestorSelectorName)) return false; return true; } return false; }
@Override public String getSelectorName() { return selectorName.getString(); }
@Override public boolean equals( Object obj ) { if (obj == this) return true; if (obj instanceof SelectorName) { SelectorName that = (SelectorName)obj; return this.name.equals(that.name()); } return false; }
/** * Create a dynamic operand that evaluates to the depth of the node identified by the selector. * * @param selectorName the name of the selector * @throws IllegalArgumentException if the selector name or property name are null */ public ChildCount( SelectorName selectorName ) { this.selectorNames = SelectorName.nameSetFrom(selectorName); }
@Override public int hashCode() { return name().hashCode(); }
Table table = context.getSchemata().getTable(selector.name().qualifiedForm(nameFactory)); if (table != null) { if (table instanceof View) context.getHints().hasView = true; context.getProblems().addError(msg, selector.aliasOrName().getString());
@Override public boolean equals( Object obj ) { if (obj == this) return true; if (obj instanceof SelectorName) { SelectorName that = (SelectorName)obj; return this.name.equals(that.name()); } return false; }
/** * Create a dynamic operand that evaluates to the qualified name of the node identified by the selector. * * @param selectorName the name of the selector */ public NodeName( SelectorName selectorName ) { this.selectorNames = SelectorName.nameSetFrom(selectorName); }
@Override public int hashCode() { return name().hashCode(); }
Table table = context.getSchemata().getTable(selector.name().qualifiedForm(nameFactory)); if (table != null) { if (table instanceof View) context.getHints().hasView = true; context.getProblems().addError(msg, selector.aliasOrName().getString());
/** * Convenience method that creates a selector name object using the supplied string. * * @param name the name of the selector; may not be null * @return the selector name; never null */ protected SelectorName selector( String name ) { return new SelectorName(name.trim()); }
@Override public String toString() { StringBuilder sb = new StringBuilder(); if (selectorName != null) { sb.append(selectorName.name()); sb.append('.'); } sb.append(propertyName); if (columnName != null) { sb.append(" AS ").append(columnName); } return sb.toString(); } }
/** * Create a dynamic operand that evaluates to the local name of the node identified by the selector. * * @param selectorName the name of the selector */ public NodeLocalName( SelectorName selectorName ) { this.selectorNames = SelectorName.nameSetFrom(selectorName); }
protected Set<Operator> operators( SelectorName tableName, String columnName, Set<Operator> defaultOperators ) { Map<String, Set<Operator>> byColumnNames = operatorsForColumnsByTableName.get(tableName.getString()); if (byColumnNames != null) { Set<Operator> ops = byColumnNames.get(columnName); if (ops != null) return ops; } return defaultOperators; }
@Override public boolean equals( Object obj ) { if (obj == this) return true; if (obj instanceof ChildNodeJoinCondition) { ChildNodeJoinCondition that = (ChildNodeJoinCondition)obj; if (this.hc != that.hc) return false; if (!this.childSelectorName.equals(that.childSelectorName)) return false; if (!this.parentSelectorName.equals(that.parentSelectorName)) return false; return true; } return false; }
@Override public int hashCode() { return selectorName().hashCode(); }
protected MutableTable( String name, List<Column> columns, boolean extraColumns ) { this.name = new SelectorName(name); this.columns.addAll(columns); for (Column column : columns) { Column existing = this.columnsByName.put(column.getName(), column); assert existing == null; } }
@Override public String toString() { StringBuilder sb = new StringBuilder(); if (selectorName != null) { sb.append(selectorName.name()); sb.append('.'); } sb.append(propertyName); if (columnName != null) { sb.append(" AS ").append(columnName); } return sb.toString(); } }
/** * Create a dynamic operand that evaluates to the full-text search score of the node identified by the selector. * * @param selectorName the name of the selector */ public FullTextSearchScore( SelectorName selectorName ) { this.selectorNames = SelectorName.nameSetFrom(selectorName); }