Enum pax_runtime::api::PaxValue
source · pub enum PaxValue {
Bool(bool),
Numeric(Numeric),
String(String),
Size(Size),
Percent(Percent),
Color(Color),
Rotation(Rotation),
Option(Box<Option<PaxValue>>),
Vec(Vec<PaxValue>),
Range(Box<PaxValue>, Box<PaxValue>),
Object(HashMap<String, PaxValue>),
Enum(String, String, Vec<PaxValue>),
}Expand description
Container for all internal pax types Two important traits are related to this type: ToFromPaxValue - responsible for converting to and from specific types (u8, String, Color, etc) CoercionRules - responsible for coercing a PaxValue to a specific type (possibly from multiple different variants)
Variants§
Bool(bool)
Numeric(Numeric)
String(String)
Size(Size)
Percent(Percent)
Color(Color)
Rotation(Rotation)
Option(Box<Option<PaxValue>>)
Vec(Vec<PaxValue>)
Range(Box<PaxValue>, Box<PaxValue>)
Object(HashMap<String, PaxValue>)
Enum(String, String, Vec<PaxValue>)
Implementations§
Trait Implementations§
source§impl CoercionRules for PaxValue
impl CoercionRules for PaxValue
source§impl<'de> Deserialize<'de> for PaxValue
impl<'de> Deserialize<'de> for PaxValue
source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PaxValue, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PaxValue, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl HelperFunctions for PaxValue
impl HelperFunctions for PaxValue
source§impl Interpolatable for PaxValue
impl Interpolatable for PaxValue
fn interpolate(&self, _other: &Self, _t: f64) -> Self
source§impl PartialOrd for PaxValue
impl PartialOrd for PaxValue
source§impl Serialize for PaxValue
impl Serialize for PaxValue
source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
source§impl ToFromPaxAny for PaxValue
impl ToFromPaxAny for PaxValue
source§impl ToPaxValue for PaxValue
impl ToPaxValue for PaxValue
fn to_pax_value(self) -> PaxValue
Auto Trait Implementations§
impl Freeze for PaxValue
impl RefUnwindSafe for PaxValue
impl Send for PaxValue
impl Sync for PaxValue
impl Unpin for PaxValue
impl UnwindSafe for PaxValue
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)source§impl<T, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
impl<T, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
source§fn round_into(self) -> U
fn round_into(self) -> U
Performs the conversion.