pub struct SearchQuery {Show 16 fields
pub limit: u8,
pub sort: Sort,
pub search_after: String,
pub offset: usize,
pub order: Order,
pub uri: String,
pub uri_parts: String,
pub wildcard_uri: String,
pub user: String,
pub group: String,
pub tag: String,
pub tags: Vec<String>,
pub any: String,
pub quote: String,
pub references: String,
pub text: String,
}Expand description
Options to filter and sort search results. See the Hypothesis API docs for more details on using these fields
Fields§
§limit: u8The maximum number of annotations to return.
Default: 20. Range: [ 0 .. 200 ]
sort: SortThe field by which annotations should be sorted One of created, updated, id, group, user
Default: updated
search_after: StringExample: “2019-01-03T19:46:09.334Z”
Define a start point for a subset (page) of annotation search results.
NOTE: make sure to set sort to Sort::Asc if using search_after
offset: usizeThe number of initial annotations to skip in the result set.
Default: 0. Range: <= 9800. search_after is more efficient.
order: OrderThe order in which the results should be sorted. One of asc, desc
Default: desc
uri: StringLimit the results to annotations matching the specific URI or equivalent URIs.
URI can be a URL (a web page address) or a URN representing another kind of resource such as DOI (Digital Object Identifier) or a PDF fingerprint.
uri_parts: StringLimit the results to annotations containing the given keyword (tokenized chunk) in the URI. The value must exactly match an individual URI keyword.
wildcard_uri: StringLimit the results to annotations whose URIs match the wildcard pattern.
user: StringLimit the results to annotations made by the specified user. (in the format acct:<username>@<authority>)
group: StringLimit the results to annotations made in the specified group (by group ID).
tag: StringLimit the results to annotations tagged with the specified value.
Similar to tag but allows a list of multiple tags.
any: StringLimit the results to annotations who contain the indicated keyword in any of the following fields:
quote, tags, text, url
quote: StringLimit the results to annotations that contain this text inside the text that was annotated.
references: StringReturns annotations that are replies to this parent annotation ID.
text: StringLimit the results to annotations that contain this text in their textual body.
Implementations§
Source§impl SearchQuery
impl SearchQuery
pub fn builder() -> SearchQueryBuilder
Trait Implementations§
Source§impl Clone for SearchQuery
impl Clone for SearchQuery
Source§fn clone(&self) -> SearchQuery
fn clone(&self) -> SearchQuery
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more