pub struct FriendState { /* private fields */ }
Expand description
Friend state format for a single friend, compatible with what C toxcore
does with on GCC x86{,_x64}
platform.
Data that is supposed to be strings (friend request message, friend name, friend status message) might, or might not even be a valid UTF-8. Anything using that data should validate whether it’s actually correct UTF-8!
feel free to add compatibility to what broken C toxcore does on other platforms
https://zetok.github.io/tox-spec/#friends-0x03
Trait Implementations§
Source§impl Clone for FriendState
impl Clone for FriendState
Source§fn clone(&self) -> FriendState
fn clone(&self) -> FriendState
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for FriendState
impl Debug for FriendState
Source§impl FromBytes for FriendState
impl FromBytes for FriendState
Source§fn from_bytes(i: &[u8]) -> IResult<&[u8], FriendState, (&[u8], ErrorKind)>
fn from_bytes(i: &[u8]) -> IResult<&[u8], FriendState, (&[u8], ErrorKind)>
Deserialize struct using
nom
from raw bytesSource§impl PartialEq for FriendState
impl PartialEq for FriendState
Source§impl ToBytes for FriendState
impl ToBytes for FriendState
impl Eq for FriendState
impl StructuralPartialEq for FriendState
Auto Trait Implementations§
impl Freeze for FriendState
impl RefUnwindSafe for FriendState
impl Send for FriendState
impl Sync for FriendState
impl Unpin for FriendState
impl UnwindSafe for FriendState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more