Struct sbr::data::CompressedInteractionsUser [−][src]
pub struct CompressedInteractionsUser<'a> { pub user_id: UserId, pub item_ids: &'a [ItemId], pub timestamps: &'a [Timestamp], }
A single user's data, arranged from earliest to latest.
Fields
user_id: UserId
User id.
item_ids: &'a [ItemId]
The users's interactions.
timestamps: &'a [Timestamp]
The timestamps of the user's interactions.
Methods
impl<'a> CompressedInteractionsUser<'a>
[src]
impl<'a> CompressedInteractionsUser<'a>
pub fn len(&self) -> usize
[src]
pub fn len(&self) -> usize
Return length of interactions.
pub fn is_empty(&self) -> bool
[src]
pub fn is_empty(&self) -> bool
If there are no interactions.
ⓘImportant traits for CompressedInteractionsUserChunkIterator<'a>pub fn chunks(
&self,
chunk_size: usize
) -> CompressedInteractionsUserChunkIterator<'a>
[src]
ⓘImportant traits for CompressedInteractionsUserChunkIterator<'a>
pub fn chunks(
&self,
chunk_size: usize
) -> CompressedInteractionsUserChunkIterator<'a>
Return a chunked iterator over interactions for this user.
The chunks are such that the first chunk is smallest,
and the remaining chunks are all of chunk_size
.
Trait Implementations
impl<'a> Debug for CompressedInteractionsUser<'a>
[src]
impl<'a> Debug for CompressedInteractionsUser<'a>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<'a> Clone for CompressedInteractionsUser<'a>
[src]
impl<'a> Clone for CompressedInteractionsUser<'a>
fn clone(&self) -> CompressedInteractionsUser<'a>
[src]
fn clone(&self) -> CompressedInteractionsUser<'a>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl<'a> Send for CompressedInteractionsUser<'a>
impl<'a> Send for CompressedInteractionsUser<'a>
impl<'a> Sync for CompressedInteractionsUser<'a>
impl<'a> Sync for CompressedInteractionsUser<'a>