Struct libsignal_service::proto::data_message::contact::PostalAddress
source · pub struct PostalAddress {
pub type: Option<i32>,
pub label: Option<String>,
pub street: Option<String>,
pub pobox: Option<String>,
pub neighborhood: Option<String>,
pub city: Option<String>,
pub region: Option<String>,
pub postcode: Option<String>,
pub country: Option<String>,
}
Fields§
§type: Option<i32>
§label: Option<String>
§street: Option<String>
§pobox: Option<String>
§neighborhood: Option<String>
§city: Option<String>
§region: Option<String>
§postcode: Option<String>
§country: Option<String>
Implementations§
source§impl PostalAddress
impl PostalAddress
sourcepub fn type(&self) -> Type
pub fn type(&self) -> Type
Returns the enum value of type
, or the default if the field is unset or set to an invalid enum value.
sourcepub fn label(&self) -> &str
pub fn label(&self) -> &str
Returns the value of label
, or the default value if label
is unset.
sourcepub fn street(&self) -> &str
pub fn street(&self) -> &str
Returns the value of street
, or the default value if street
is unset.
sourcepub fn pobox(&self) -> &str
pub fn pobox(&self) -> &str
Returns the value of pobox
, or the default value if pobox
is unset.
sourcepub fn neighborhood(&self) -> &str
pub fn neighborhood(&self) -> &str
Returns the value of neighborhood
, or the default value if neighborhood
is unset.
sourcepub fn region(&self) -> &str
pub fn region(&self) -> &str
Returns the value of region
, or the default value if region
is unset.
Trait Implementations§
source§impl Clone for PostalAddress
impl Clone for PostalAddress
source§fn clone(&self) -> PostalAddress
fn clone(&self) -> PostalAddress
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 PostalAddress
impl Debug for PostalAddress
source§impl Default for PostalAddress
impl Default for PostalAddress
source§impl Message for PostalAddress
impl Message for PostalAddress
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message to a buffer. Read more
source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message to a newly allocated buffer.
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message with a length-delimiter to a buffer. Read more
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes an instance of the message from a buffer. Read more
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self
.source§impl PartialEq for PostalAddress
impl PartialEq for PostalAddress
source§fn eq(&self, other: &PostalAddress) -> bool
fn eq(&self, other: &PostalAddress) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for PostalAddress
Auto Trait Implementations§
impl Freeze for PostalAddress
impl RefUnwindSafe for PostalAddress
impl Send for PostalAddress
impl Sync for PostalAddress
impl Unpin for PostalAddress
impl UnwindSafe for PostalAddress
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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§impl<T> PartialDefault for Twhere
T: Default,
impl<T> PartialDefault for Twhere
T: Default,
§fn partial_default() -> T
fn partial_default() -> T
Returns a value that can be safely dropped or assigned over.