Trait glib::value::FromValue [−][src]
pub unsafe trait FromValue<'a>: Sized { type Checker: ValueTypeChecker; unsafe fn from_value(value: &'a Value) -> Self; }
Expand description
Associated Types
type Checker: ValueTypeChecker
type Checker: ValueTypeChecker
Value type checker.
Required methods
unsafe fn from_value(value: &'a Value) -> Self
unsafe fn from_value(value: &'a Value) -> Self
Get the contained value from a Value
.
Safety
Self::Checker::check()
must be called first and must not fail.
Implementations on Foreign Types
type Checker = GenericValueTypeChecker<Self>
impl<'a, T, C> FromValue<'a> for Option<T> where
T: FromValue<'a, Checker = C> + StaticType,
C: ValueTypeChecker<Error = ValueTypeMismatchOrNoneError>,
impl<'a, T, C> FromValue<'a> for Option<T> where
T: FromValue<'a, Checker = C> + StaticType,
C: ValueTypeChecker<Error = ValueTypeMismatchOrNoneError>,
Blanket implementation for all optional types.
type Checker = GenericValueTypeChecker<T>
type Checker = GenericValueTypeOrNoneChecker<Self>
type Checker = GenericValueTypeOrNoneChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>
type Checker = GenericValueTypeChecker<Self>