pub struct Collection { /* private fields */ }
Implementations§
Methods from Deref<Target = Data>§
Sourcepub fn result_condition<'life0, 'life_self, 'async_recursion>(
&'life_self self,
condition: &'life0 Condition<'_>,
) -> Pin<Box<dyn Future<Output = BTreeSet<NonZero<u32>>> + 'async_recursion>>where
'life0: 'async_recursion,
'life_self: 'async_recursion,
pub fn result_condition<'life0, 'life_self, 'async_recursion>(
&'life_self self,
condition: &'life0 Condition<'_>,
) -> Pin<Box<dyn Future<Output = BTreeSet<NonZero<u32>>> + 'async_recursion>>where
'life0: 'async_recursion,
'life_self: 'async_recursion,
Returns search results by specifying Condition.
pub fn result_field( &self, name: &Arc<String>, condition: &Field, ) -> BTreeSet<NonZero<u32>>
Sourcepub fn begin_search(&self) -> Search<'_>
pub fn begin_search(&self) -> Search<'_>
Create a new Search object.
Sourcepub fn search_field<'a>(
&'a self,
name: Arc<String>,
condition: &'a Field,
) -> Search<'a>
pub fn search_field<'a>( &'a self, name: Arc<String>, condition: &'a Field, ) -> Search<'a>
Create a Search object with the field search set.
Sourcepub fn search_activity<'a>(&'a self, condition: Activity) -> Search<'a>
pub fn search_activity<'a>(&'a self, condition: Activity) -> Search<'a>
Create a Search object with the activity search set.
Sourcepub fn search_term<'a>(&'a self, condition: Term) -> Search<'a>
pub fn search_term<'a>(&'a self, condition: Term) -> Search<'a>
Create a Search object with the term search set.
Sourcepub fn search_row<'a>(&'a self, condition: &'a Number) -> Search<'a>
pub fn search_row<'a>(&'a self, condition: &'a Number) -> Search<'a>
Create a Search object with the row search set.
Sourcepub fn search_default(&self) -> Search<'_>
pub fn search_default(&self) -> Search<'_>
Creates a Search object with a default search set. Searches for data whose term is greater than or equal to the current date and time and is active.
Sourcepub fn field_bytes(&self, row: NonZero<u32>, name: &Arc<String>) -> &[u8] ⓘ
pub fn field_bytes(&self, row: NonZero<u32>, name: &Arc<String>) -> &[u8] ⓘ
Returns the value of the field with the specified name in the specified row as a slice.
Sourcepub fn field_num(&self, row: NonZero<u32>, name: &Arc<String>) -> f64
pub fn field_num(&self, row: NonZero<u32>, name: &Arc<String>) -> f64
Returns the value of the field with the specified name in the specified row as a number.
pub fn fields(&self) -> &HashMap<Arc<String>, IdxBinary>
Sourcepub async fn insert(
&mut self,
activity: Activity,
term_begin: Term,
term_end: Term,
fields: HashMap<Arc<String>, Vec<u8>>,
) -> NonZero<u32>
pub async fn insert( &mut self, activity: Activity, term_begin: Term, term_end: Term, fields: HashMap<Arc<String>, Vec<u8>>, ) -> NonZero<u32>
Delete row.
Sourcepub async fn update(
&mut self,
row: NonZero<u32>,
activity: Activity,
term_begin: Term,
term_end: Term,
fields: HashMap<Arc<String>, Vec<u8>>,
)
pub async fn update( &mut self, row: NonZero<u32>, activity: Activity, term_begin: Term, term_end: Term, fields: HashMap<Arc<String>, Vec<u8>>, )
Update row.
Sourcepub fn sort<C>(
&self,
rows: &BTreeSet<NonZero<u32>>,
orders: &[Order<C>],
) -> Vec<NonZero<u32>>where
C: CustomSort,
pub fn sort<C>(
&self,
rows: &BTreeSet<NonZero<u32>>,
orders: &[Order<C>],
) -> Vec<NonZero<u32>>where
C: CustomSort,
Sort search results.
Sourcepub fn serial(&self, row: NonZero<u32>) -> &u32
pub fn serial(&self, row: NonZero<u32>) -> &u32
Returns a serial number.The serial number is incremented each time data is added.
Sourcepub fn uuid(&self, row: NonZero<u32>) -> Option<&u128>
pub fn uuid(&self, row: NonZero<u32>) -> Option<&u128>
Returns a UUID.UUID is a unique ID that is automatically generated when data is registered..
Sourcepub fn activity(&self, row: NonZero<u32>) -> Option<Activity>
pub fn activity(&self, row: NonZero<u32>) -> Option<Activity>
Returns the activity value. activity is used to indicate whether data is valid or invalid.
Sourcepub fn term_begin(&self, row: NonZero<u32>) -> Option<&u64>
pub fn term_begin(&self, row: NonZero<u32>) -> Option<&u64>
Returns the start date and time of the data’s validity period.
Sourcepub fn term_end(&self, row: NonZero<u32>) -> Option<&u64>
pub fn term_end(&self, row: NonZero<u32>) -> Option<&u64>
Returns the end date and time of the data’s validity period.