Example usage for org.springframework.data.solr.core.query Crotch Crotch

List of usage examples for org.springframework.data.solr.core.query Crotch Crotch

Introduction

In this page you can find the example usage for org.springframework.data.solr.core.query Crotch Crotch.

Prototype

Crotch() 

Source Link

Usage

From source file:org.springframework.data.solr.core.query.Criteria.java

/**
 * Explicitly wrap {@link Criteria} inside not operation.
 * /*from w w  w.  j  a  v a 2s. c o  m*/
 * @since 1.4
 * @return
 */
public Criteria notOperator() {

    Crotch c = new Crotch();
    c.setNegating(true);
    c.add(this);

    return c;
}

From source file:org.springframework.data.solr.core.query.Criteria.java

/**
 * Explicitly connect {@link Criteria} with another one allows to create explicit bracketing.
 * //from   ww  w .  j a v  a 2 s  .c  om
 * @since 1.4
 * @return
 */
public Criteria connect() {
    Crotch c = new Crotch();
    c.add(this);
    return c;
}

From source file:org.springframework.data.solr.core.query.Criteria.java

@SuppressWarnings("unchecked")
@Override/*from  ww  w .j  a  va2s  .  c  o  m*/
public Crotch and(Node node) {

    if (!(node instanceof Criteria)) {
        throw new IllegalArgumentException("Can only add instances of Criteria");
    }

    Crotch crotch = new Crotch();
    crotch.setParent(this.getParent());
    crotch.add(this);
    crotch.add((Criteria) node);
    return crotch;
}

From source file:org.springframework.data.solr.core.query.Criteria.java

@SuppressWarnings("unchecked")
public Crotch or(Node node) {

    if (!(node instanceof Criteria)) {
        throw new IllegalArgumentException("Can only add instances of Criteria");
    }/*  www  .  j a v a  2s. com*/

    node.setPartIsOr(true);

    Crotch crotch = new Crotch();
    crotch.setParent(this.getParent());
    crotch.add(this);
    crotch.add((Criteria) node);
    return crotch;
}