Scrypath.Query (scrypath v0.3.0)

Copy Markdown View Source

Internal normalized search query struct used by the common search path and backend adapters.

Summary

Types

Normalized pagination options.

t()

Internal normalized search query.

Types

page_t()

@type page_t() :: %{
  optional(:number) => pos_integer(),
  optional(:size) => pos_integer()
}

Normalized pagination options.

t()

@type t() :: %Scrypath.Query{
  filter: keyword(),
  page: page_t(),
  sort: keyword(),
  text: String.t()
}

Internal normalized search query.

Functions

new(text, opts)

@spec new(
  String.t(),
  keyword()
) :: t()