mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-27 04:25:06 +08:00
Remove useless where clauses for the criteria
This commit is contained in:
parent
07784c8990
commit
1fc25148da
@ -37,7 +37,7 @@ impl<'t> AscDesc<'t> {
|
|||||||
candidates: Option<RoaringBitmap>,
|
candidates: Option<RoaringBitmap>,
|
||||||
field_id: FieldId,
|
field_id: FieldId,
|
||||||
facet_type: FacetType,
|
facet_type: FacetType,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Self::initial(index, rtxn, query_tree, candidates, field_id, facet_type, true)
|
Self::initial(index, rtxn, query_tree, candidates, field_id, facet_type, true)
|
||||||
}
|
}
|
||||||
@ -49,7 +49,7 @@ impl<'t> AscDesc<'t> {
|
|||||||
candidates: Option<RoaringBitmap>,
|
candidates: Option<RoaringBitmap>,
|
||||||
field_id: FieldId,
|
field_id: FieldId,
|
||||||
facet_type: FacetType,
|
facet_type: FacetType,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Self::initial(index, rtxn, query_tree, candidates, field_id, facet_type, false)
|
Self::initial(index, rtxn, query_tree, candidates, field_id, facet_type, false)
|
||||||
}
|
}
|
||||||
@ -60,7 +60,7 @@ impl<'t> AscDesc<'t> {
|
|||||||
parent: Box<dyn Criterion + 't>,
|
parent: Box<dyn Criterion + 't>,
|
||||||
field_id: FieldId,
|
field_id: FieldId,
|
||||||
facet_type: FacetType,
|
facet_type: FacetType,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Self::new(index, rtxn, parent, field_id, facet_type, true)
|
Self::new(index, rtxn, parent, field_id, facet_type, true)
|
||||||
}
|
}
|
||||||
@ -71,7 +71,7 @@ impl<'t> AscDesc<'t> {
|
|||||||
parent: Box<dyn Criterion + 't>,
|
parent: Box<dyn Criterion + 't>,
|
||||||
field_id: FieldId,
|
field_id: FieldId,
|
||||||
facet_type: FacetType,
|
facet_type: FacetType,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Self::new(index, rtxn, parent, field_id, facet_type, false)
|
Self::new(index, rtxn, parent, field_id, facet_type, false)
|
||||||
}
|
}
|
||||||
@ -84,7 +84,7 @@ impl<'t> AscDesc<'t> {
|
|||||||
field_id: FieldId,
|
field_id: FieldId,
|
||||||
facet_type: FacetType,
|
facet_type: FacetType,
|
||||||
ascending: bool,
|
ascending: bool,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
let faceted_candidates = index.faceted_documents_ids(rtxn, field_id)?;
|
let faceted_candidates = index.faceted_documents_ids(rtxn, field_id)?;
|
||||||
let candidates = match &query_tree {
|
let candidates = match &query_tree {
|
||||||
@ -120,7 +120,7 @@ impl<'t> AscDesc<'t> {
|
|||||||
field_id: FieldId,
|
field_id: FieldId,
|
||||||
facet_type: FacetType,
|
facet_type: FacetType,
|
||||||
ascending: bool,
|
ascending: bool,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Ok(AscDesc {
|
Ok(AscDesc {
|
||||||
index,
|
index,
|
||||||
|
@ -22,7 +22,7 @@ impl<'t> Proximity<'t> {
|
|||||||
ctx: &'t dyn Context,
|
ctx: &'t dyn Context,
|
||||||
query_tree: Option<Operation>,
|
query_tree: Option<Operation>,
|
||||||
candidates: Option<RoaringBitmap>,
|
candidates: Option<RoaringBitmap>,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Ok(Proximity {
|
Ok(Proximity {
|
||||||
ctx,
|
ctx,
|
||||||
@ -38,7 +38,7 @@ impl<'t> Proximity<'t> {
|
|||||||
pub fn new(
|
pub fn new(
|
||||||
ctx: &'t dyn Context,
|
ctx: &'t dyn Context,
|
||||||
parent: Box<dyn Criterion + 't>,
|
parent: Box<dyn Criterion + 't>,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Ok(Proximity {
|
Ok(Proximity {
|
||||||
ctx,
|
ctx,
|
||||||
|
@ -24,7 +24,7 @@ impl<'t> Typo<'t> {
|
|||||||
ctx: &'t dyn Context,
|
ctx: &'t dyn Context,
|
||||||
query_tree: Option<Operation>,
|
query_tree: Option<Operation>,
|
||||||
candidates: Option<RoaringBitmap>,
|
candidates: Option<RoaringBitmap>,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Ok(Typo {
|
Ok(Typo {
|
||||||
ctx,
|
ctx,
|
||||||
@ -41,7 +41,7 @@ impl<'t> Typo<'t> {
|
|||||||
pub fn new(
|
pub fn new(
|
||||||
ctx: &'t dyn Context,
|
ctx: &'t dyn Context,
|
||||||
parent: Box<dyn Criterion + 't>,
|
parent: Box<dyn Criterion + 't>,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Ok(Typo {
|
Ok(Typo {
|
||||||
ctx,
|
ctx,
|
||||||
|
@ -21,7 +21,7 @@ impl<'t> Words<'t> {
|
|||||||
ctx: &'t dyn Context,
|
ctx: &'t dyn Context,
|
||||||
query_tree: Option<Operation>,
|
query_tree: Option<Operation>,
|
||||||
candidates: Option<RoaringBitmap>,
|
candidates: Option<RoaringBitmap>,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Ok(Words {
|
Ok(Words {
|
||||||
ctx,
|
ctx,
|
||||||
@ -36,7 +36,7 @@ impl<'t> Words<'t> {
|
|||||||
pub fn new(
|
pub fn new(
|
||||||
ctx: &'t dyn Context,
|
ctx: &'t dyn Context,
|
||||||
parent: Box<dyn Criterion + 't>,
|
parent: Box<dyn Criterion + 't>,
|
||||||
) -> anyhow::Result<Self> where Self: Sized
|
) -> anyhow::Result<Self>
|
||||||
{
|
{
|
||||||
Ok(Words {
|
Ok(Words {
|
||||||
ctx,
|
ctx,
|
||||||
|
Loading…
Reference in New Issue
Block a user