com.codemettle.akkasolr.querybuilder

SolrQueryBuilder

case class SolrQueryBuilder(query: String, rowsOpt: Option[Int] = scala.None, startOpt: Option[Int] = scala.None, fieldList: Vector[String] = ..., sortsList: Vector[SortClause] = ..., facetFields: Vector[String] = ..., serverTimeAllowed: Option[Int] = scala.None) extends Product with Serializable

An (incomplete) immutable builder for Solr queries. Currently only has common org.apache.solr.client.solrj.SolrQuery shortcuts, but more can be added easily as the need arises.

Sample Usage
import com.codemettle.akkasolr.client.SolrQueryBuilder.FieldStrToSort

val b = SolrQueryBuilder("*") rows 21 fields "field" sortBy "myfield".desc
val b2 = b facets "facetfield"
query(b.toParams)
query(b2.toParams)
Annotations
@SerialVersionUID( 1L )
Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. SolrQueryBuilder
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. AnyRef
  7. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new SolrQueryBuilder(query: String, rowsOpt: Option[Int] = scala.None, startOpt: Option[Int] = scala.None, fieldList: Vector[String] = ..., sortsList: Vector[SortClause] = ..., facetFields: Vector[String] = ..., serverTimeAllowed: Option[Int] = scala.None)

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. def allowedExecutionTime(duration: Duration): SolrQueryBuilder

  7. def allowedExecutionTime(duration: FiniteDuration): SolrQueryBuilder

  8. def allowedExecutionTime(millis: Int): SolrQueryBuilder

  9. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  10. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  12. val facetFields: Vector[String]

  13. def facets(fs: String*): SolrQueryBuilder

  14. val fieldList: Vector[String]

  15. def fields(fs: String*): SolrQueryBuilder

  16. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  17. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  18. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  19. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  20. final def notify(): Unit

    Definition Classes
    AnyRef
  21. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  22. val query: String

  23. def rows(r: Int): SolrQueryBuilder

  24. val rowsOpt: Option[Int]

  25. val serverTimeAllowed: Option[Int]

  26. def sortBy(scs: SortClause*): SolrQueryBuilder

  27. def sortBy(sc: SortClause): SolrQueryBuilder

  28. val sortsList: Vector[SortClause]

  29. def start(s: Int): SolrQueryBuilder

  30. val startOpt: Option[Int]

  31. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  32. def toParams: ImmutableSolrParams

    Create a SolrParams object that can be used for Solr queries

    Create a SolrParams object that can be used for Solr queries

    returns

    an ImmutableSolrParams representing the state of the builder

  33. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  34. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  35. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  36. def withFacetField(f: String): SolrQueryBuilder

  37. def withFacetFields(fs: String*): SolrQueryBuilder

  38. def withField(f: String): SolrQueryBuilder

  39. def withFields(fs: String*): SolrQueryBuilder

  40. def withQuery(qp: QueryPart)(implicit arf: ActorRefFactory): SolrQueryBuilder

  41. def withQuery(q: String): SolrQueryBuilder

  42. def withSort(sc: SortClause): SolrQueryBuilder

  43. def withSorts(scs: SortClause*): SolrQueryBuilder

  44. def withoutAllowedExecutionTime(): SolrQueryBuilder

  45. def withoutFacetField(f: String): SolrQueryBuilder

  46. def withoutFacetFields(): SolrQueryBuilder

  47. def withoutFacetFields(fs: String*): SolrQueryBuilder

  48. def withoutField(f: String): SolrQueryBuilder

  49. def withoutFields(): SolrQueryBuilder

  50. def withoutFields(fs: String*): SolrQueryBuilder

  51. def withoutRows(): SolrQueryBuilder

  52. def withoutSort(sc: SortClause): SolrQueryBuilder

  53. def withoutSortField(f: String): SolrQueryBuilder

  54. def withoutSorts(): SolrQueryBuilder

  55. def withoutStart(): SolrQueryBuilder

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped