Packages

final class Query extends QueryOps with Renderable

Collection representation of a query string

It is a indexed sequence of key and maybe a value pairs which maps precisely to a query string, modulo the identity of separators.

When rendered, the resulting String will have the pairs separated by '&' while the key is separated from the value with '='

Source
Query.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Query
  2. Renderable
  3. QueryOps
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. def +*?[T](values: Seq[T])(implicit arg0: QueryParam[T], arg1: QueryParamEncoder[T]): Self

    alias for withQueryParam

    alias for withQueryParam

    Definition Classes
    QueryOps
  2. def +*?[T](value: T)(implicit arg0: QueryParamKeyLike[T], arg1: QueryParamEncoder[T]): Self

    alias for withQueryParam

    alias for withQueryParam

    Definition Classes
    QueryOps
  3. def ++(pairs: Iterable[(String, Option[String])]): Query
  4. def ++?[K, T](param: (K, Seq[T]))(implicit arg0: QueryParamKeyLike[K], arg1: QueryParamEncoder[T]): Self

    alias for withQueryParam

    alias for withQueryParam

    Definition Classes
    QueryOps
  5. def +:(elem: KeyValue): Query
  6. def +?[K](name: K)(implicit arg0: QueryParamKeyLike[K]): Self

    alias for withQueryParam

    alias for withQueryParam

    Definition Classes
    QueryOps
  7. def +?[K, T](param: (K, T))(implicit arg0: QueryParamKeyLike[K], arg1: QueryParamEncoder[T]): Self

    alias for withQueryParam

    alias for withQueryParam

    Definition Classes
    QueryOps
  8. def +?[T](implicit arg0: QueryParam[T]): Self

    alias for withQueryParam

    alias for withQueryParam

    Definition Classes
    QueryOps
  9. def +??[T](value: Option[T])(implicit arg0: QueryParam[T], arg1: QueryParamEncoder[T]): Self

    alias for withOptionQueryParam

    alias for withOptionQueryParam

    Definition Classes
    QueryOps
  10. def +??[K, T](param: (K, Option[T]))(implicit arg0: QueryParamKeyLike[K], arg1: QueryParamEncoder[T]): Self

    alias for withOptionQueryParam

    alias for withOptionQueryParam

    Definition Classes
    QueryOps
  11. def -?[K](key: K)(implicit arg0: QueryParamKeyLike[K]): Self

    alias for removeQueryParam

    alias for removeQueryParam

    Definition Classes
    QueryOps
  12. def -?[T](implicit key: QueryParam[T]): Self

    alias for removeQueryParam

    alias for removeQueryParam

    Definition Classes
    QueryOps
  13. def :+(elem: KeyValue): Query
  14. def =?[T](q: Map[String, List[T]])(implicit arg0: QueryParamEncoder[T]): Self

    alias for setQueryParams

    alias for setQueryParams

    Definition Classes
    QueryOps
  15. def ?[K](name: K)(implicit arg0: QueryParamKeyLike[K]): Boolean

    alias for containsQueryParam

    alias for containsQueryParam

    Definition Classes
    QueryOps
  16. def apply(idx: Int): KeyValue
  17. def containsQueryParam[K](key: K)(implicit arg0: QueryParamKeyLike[K]): Boolean
    Definition Classes
    QueryOps
  18. def containsQueryParam[T](implicit key: QueryParam[T]): Boolean

    Checks if a specified parameter exists in the Query.

    Checks if a specified parameter exists in the Query. A parameter without a name can be checked with an empty string.

    Definition Classes
    QueryOps
  19. def drop(n: Int): Query
  20. def dropRight(n: Int): Query
  21. def equals(that: Any): Boolean
    Definition Classes
    Query → AnyRef → Any
  22. def exists(f: (KeyValue) ⇒ Boolean): Boolean
  23. def filter(f: (KeyValue) ⇒ Boolean): Query
  24. def filterNot(f: (KeyValue) ⇒ Boolean): Query
  25. def foldLeft[Z](z: Z)(f: (Z, KeyValue) ⇒ Z): Z
  26. def foldRight[Z](z: Eval[Z])(f: (KeyValue, Eval[Z]) ⇒ Eval[Z]): Eval[Z]
  27. def foreach(f: (KeyValue) ⇒ Unit): Unit
  28. def hashCode(): Int
    Definition Classes
    Query → AnyRef → Any
  29. def isEmpty: Boolean
  30. def length: Int
  31. lazy val multiParams: Map[String, Seq[String]]

    Map[String, Seq[String]] representation of the Query

    Map[String, Seq[String]] representation of the Query

    Params are represented as a Seq[String] and may be empty.

  32. def nonEmpty: Boolean
  33. def pairs: Vector[KeyValue]
  34. lazy val params: Map[String, String]

    Map[String, String] representation of the Query

    Map[String, String] representation of the Query

    If multiple values exist for a key, the first is returned. If none exist, the empty String "" is returned.

  35. def removeQueryParam[K](key: K)(implicit arg0: QueryParamKeyLike[K]): Self

    Creates maybe a new Self without the specified parameter in query.

    Creates maybe a new Self without the specified parameter in query. If no parameter with the given key exists then this will be returned.

    Definition Classes
    QueryOps
  36. def render(writer: Writer): writer.type

    Render the Query as a String.

    Render the Query as a String.

    Pairs are separated by '&' and keys are separated from values by '='

    Definition Classes
    QueryRenderable
  37. def renderString: String

    Generates a String rendering of this object

    Generates a String rendering of this object

    Definition Classes
    Renderable
  38. def setQueryParams[K, T](params: Map[K, Seq[T]])(implicit arg0: QueryParamKeyLike[K], arg1: QueryParamEncoder[T]): Self

    Creates maybe a new Self with the specified parameters.

    Creates maybe a new Self with the specified parameters. The entire Query will be replaced with the given one.

    Definition Classes
    QueryOps
  39. def slice(from: Int, until: Int): Query
  40. def toList: List[(String, Option[String])]
  41. def toString(): String
    Definition Classes
    Renderable → Any
  42. def toVector: Vector[(String, Option[String])]
  43. def withMultiValueQueryParams[T, K](params: Map[K, Seq[T]])(implicit arg0: QueryParamEncoder[T], arg1: QueryParamKeyLike[K]): Self

    Creates maybe a new Self with all the specified parameters in the Query.

    Creates maybe a new Self with all the specified parameters in the Query. If any of the given parameters' keys already exists, the value(s) will be replaced. Parameters from the input map are added left-to-right, so if a parameter with a given key is specified more than once, it will be self-overwriting.

    Definition Classes
    QueryOps
  44. def withOptionQueryParam[T](value: Option[T])(implicit arg0: QueryParam[T], arg1: QueryParamEncoder[T]): Self

    Creates maybe a new Self with the specified parameter in the Query.

    Creates maybe a new Self with the specified parameter in the Query. If the value is empty or if the parameter to be added equal the existing entry the same instance of Self will be returned. If a parameter with the given name already exists the values will be replaced.

    Definition Classes
    QueryOps
  45. def withOptionQueryParam[T, K](key: K, value: Option[T])(implicit arg0: QueryParamEncoder[T], arg1: QueryParamKeyLike[K]): Self

    Creates maybe a new Self with the specified parameter in the Query.

    Creates maybe a new Self with the specified parameter in the Query. If the value is empty or if the parameter to be added equal the existing entry the same instance of Self will be returned. If a parameter with the given key already exists the values will be replaced.

    Definition Classes
    QueryOps
  46. def withQueryParam[T, K](key: K, values: Seq[T])(implicit arg0: QueryParamEncoder[T], arg1: QueryParamKeyLike[K]): Self

    Creates maybe a new Self with the specified parameters in the Query.

    Creates maybe a new Self with the specified parameters in the Query. If a parameter with the given key already exists the values will be replaced.

    Definition Classes
    QueryOps
  47. def withQueryParam[T, K](key: K, value: T)(implicit arg0: QueryParamEncoder[T], arg1: QueryParamKeyLike[K]): Self

    Creates maybe a new Self with the specified parameter in the Query.

    Creates maybe a new Self with the specified parameter in the Query. If a parameter with the given key already exists the values will be replaced. If the parameter to be added equal the existing entry the same instance of Self will be returned.

    Definition Classes
    QueryOps
  48. def withQueryParam[K](key: K)(implicit arg0: QueryParamKeyLike[K]): Self

    Creates a new Self with the specified parameter in the Query.

    Creates a new Self with the specified parameter in the Query. If a parameter with the given key already exists the values will be replaced with an empty list.

    Definition Classes
    QueryOps
  49. def withQueryParam[T](implicit arg0: QueryParam[T]): Self

    Creates a new Self with the specified parameter in the Query.

    Creates a new Self with the specified parameter in the Query. If a parameter with the given QueryParam.key already exists the values will be replaced with an empty list.

    Definition Classes
    QueryOps
  50. def withQueryParams[T, K](params: Map[K, T])(implicit arg0: QueryParamEncoder[T], arg1: QueryParamKeyLike[K]): Self

    Creates maybe a new Self with all the specified parameters in the Query.

    Creates maybe a new Self with all the specified parameters in the Query. If any of the given parameters' keys already exists, the value(s) will be replaced. Parameters from the input map are added left-to-right, so if a parameter with a given key is specified more than once, it will be self-overwriting.

    Definition Classes
    QueryOps