MCPcopy Create free account
hub / github.com/Autoparallel/learner / order_by

Method order_by

crates/learner/src/database/instruction/query.rs:255–258  ·  view source on GitHub ↗

Sets the field to order results by. # Arguments `field` - The field to sort by # Examples ```no_run # use learner::database::{Query, OrderField}; let query = Query::list_all().order_by(OrderField::PublicationDate); ```

(mut self, field: OrderField)

Source from the content-addressed store, hash-verified

253 /// let query = Query::list_all().order_by(OrderField::PublicationDate);
254 /// ```
255 pub fn order_by(mut self, field: OrderField) -> Self {
256 self.order_by = Some(field);
257 self
258 }
259
260 /// Sets the order to descending (default is ascending).
261 ///

Callers 8

newMethod · 0.80
refresh_papersMethod · 0.80
test_multiple_sourcesFunction · 0.80
test_date_orderingFunction · 0.80
test_title_orderingFunction · 0.80

Calls

no outgoing calls

Tested by 6

test_multiple_sourcesFunction · 0.64
test_date_orderingFunction · 0.64
test_title_orderingFunction · 0.64