Struct glib::VariantType
[−]
[src]
pub struct VariantType { /* fields omitted */ }
Describes Variant
types.
The Variant
type system (based on the D-Bus one) describes types with
"type strings". VariantType
is an owned immutable type string (you can
think of it as a Box<str>
statically guaranteed to be a valid type
string), &VariantTy
is a borrowed one (like &str
).
Methods
impl VariantType
[src]
pub fn new(type_string: &str) -> Result<VariantType, ()>
[src]
Tries to create a VariantType
from a string slice.
Returns Ok
if the string is a valid type string, Err
otherwise.
Methods from Deref<Target = VariantTy>
Trait Implementations
impl Send for VariantType
[src]
impl Sync for VariantType
[src]
impl Drop for VariantType
[src]
impl Borrow<VariantTy> for VariantType
[src]
impl Clone for VariantType
[src]
fn clone(&self) -> VariantType
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Deref for VariantType
[src]
type Target = VariantTy
The resulting type after dereferencing.
fn deref(&self) -> &VariantTy
[src]
Dereferences the value.
impl Debug for VariantType
[src]
fn fmt(&self, f: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Display for VariantType
[src]
fn fmt(&self, f: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Hash for VariantType
[src]
fn hash<H: Hasher>(&self, state: &mut H)
[src]
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl<'a> Into<Cow<'a, VariantTy>> for VariantType
[src]
impl PartialEq for VariantType
[src]
fn eq(&self, other: &Self) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<VariantTy> for VariantType
[src]
fn eq(&self, other: &VariantTy) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<VariantType> for VariantTy
[src]
fn eq(&self, other: &VariantType) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<&'a VariantTy> for VariantType
[src]
fn eq(&self, other: &&'a VariantTy) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<VariantType> for &'a VariantTy
[src]
fn eq(&self, other: &VariantType) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<Cow<'a, VariantTy>> for VariantType
[src]
fn eq(&self, other: &Cow<'a, VariantTy>) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<VariantType> for Cow<'a, VariantTy>
[src]
fn eq(&self, other: &VariantType) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<str> for VariantType
[src]
fn eq(&self, other: &str) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<VariantType> for str
[src]
fn eq(&self, other: &VariantType) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<&'a str> for VariantType
[src]
fn eq(&self, other: &&'a str) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<VariantType> for &'a str
[src]
fn eq(&self, other: &VariantType) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<String> for VariantType
[src]
fn eq(&self, other: &String) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl<'a, 'b> PartialEq<VariantType> for String
[src]
fn eq(&self, other: &VariantType) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.