SelectorName selector = mapping.getSingleMappedSelectorName();
node.addSelector(selector);
return new DescendantNode(selector, descendantNode.getAncestorPath());
}
if (constraint instanceof PropertyExistence) {
PropertyExistence existence = (PropertyExistence)constraint;
if (!mapping.getOriginalName().equals(existence.getSelectorName())) return existence;
Column sourceColumn = mapping.getMappedColumn(existence.getPropertyName());
if (sourceColumn == null) return existence;
node.addSelector(sourceColumn.getSelectorName());
return new PropertyExistence(sourceColumn.getSelectorName(), sourceColumn.getPropertyName());
}
if (constraint instanceof FullTextSearch) {
FullTextSearch search = (FullTextSearch)constraint;
if (!mapping.getOriginalName().equals(search.getSelectorName())) return search;
Column sourceColumn = mapping.getMappedColumn(search.getPropertyName());