#[non_exhaustive]pub enum Variant {
Show 38 variants
Axes(Axes),
BinaryString(BinaryString),
Bool(bool),
BrickColor(BrickColor),
CFrame(CFrame),
Color3(Color3),
Color3uint8(Color3uint8),
ColorSequence(ColorSequence),
Content(Content),
Enum(Enum),
Faces(Faces),
Float32(f32),
Float64(f64),
Int32(i32),
Int64(i64),
NumberRange(NumberRange),
NumberSequence(NumberSequence),
PhysicalProperties(PhysicalProperties),
Ray(Ray),
Rect(Rect),
Ref(Ref),
Region3(Region3),
Region3int16(Region3int16),
SharedString(SharedString),
String(String),
UDim(UDim),
UDim2(UDim2),
Vector2(Vector2),
Vector2int16(Vector2int16),
Vector3(Vector3),
Vector3int16(Vector3int16),
OptionalCFrame(Option<CFrame>),
Tags(Tags),
Attributes(Attributes),
Font(Font),
UniqueId(UniqueId),
MaterialColors(MaterialColors),
SecurityCapabilities(SecurityCapabilities),
}
Expand description
Represents any Roblox type. Useful for operating generically on Roblox instances.
Stability
New variants may be added to Variant
in minor releases. As
such, it is marked #[non_exhaustive]
.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Axes(Axes)
BinaryString(BinaryString)
Bool(bool)
BrickColor(BrickColor)
CFrame(CFrame)
Color3(Color3)
Color3uint8(Color3uint8)
ColorSequence(ColorSequence)
Content(Content)
Enum(Enum)
Faces(Faces)
Float32(f32)
Float64(f64)
Int32(i32)
Int64(i64)
NumberRange(NumberRange)
NumberSequence(NumberSequence)
PhysicalProperties(PhysicalProperties)
Ray(Ray)
Rect(Rect)
Ref(Ref)
Region3(Region3)
Region3int16(Region3int16)
String(String)
UDim(UDim)
UDim2(UDim2)
Vector2(Vector2)
Vector2int16(Vector2int16)
Vector3(Vector3)
Vector3int16(Vector3int16)
OptionalCFrame(Option<CFrame>)
Tags(Tags)
Attributes(Attributes)
Font(Font)
UniqueId(UniqueId)
MaterialColors(MaterialColors)
SecurityCapabilities(SecurityCapabilities)
Implementations§
Trait Implementations§
source§impl From<Attributes> for Variant
impl From<Attributes> for Variant
source§fn from(value: Attributes) -> Self
fn from(value: Attributes) -> Self
Converts to this type from the input type.
source§impl From<BinaryString> for Variant
impl From<BinaryString> for Variant
source§fn from(value: BinaryString) -> Self
fn from(value: BinaryString) -> Self
Converts to this type from the input type.
source§impl From<BrickColor> for Variant
impl From<BrickColor> for Variant
source§fn from(value: BrickColor) -> Self
fn from(value: BrickColor) -> Self
Converts to this type from the input type.
source§impl From<Color3uint8> for Variant
impl From<Color3uint8> for Variant
source§fn from(value: Color3uint8) -> Self
fn from(value: Color3uint8) -> Self
Converts to this type from the input type.
source§impl From<ColorSequence> for Variant
impl From<ColorSequence> for Variant
source§fn from(value: ColorSequence) -> Self
fn from(value: ColorSequence) -> Self
Converts to this type from the input type.
source§impl From<MaterialColors> for Variant
impl From<MaterialColors> for Variant
source§fn from(value: MaterialColors) -> Self
fn from(value: MaterialColors) -> Self
Converts to this type from the input type.
source§impl From<NumberRange> for Variant
impl From<NumberRange> for Variant
source§fn from(value: NumberRange) -> Self
fn from(value: NumberRange) -> Self
Converts to this type from the input type.
source§impl From<NumberSequence> for Variant
impl From<NumberSequence> for Variant
source§fn from(value: NumberSequence) -> Self
fn from(value: NumberSequence) -> Self
Converts to this type from the input type.
source§impl From<PhysicalProperties> for Variant
impl From<PhysicalProperties> for Variant
source§fn from(value: PhysicalProperties) -> Self
fn from(value: PhysicalProperties) -> Self
Converts to this type from the input type.
source§impl From<Region3int16> for Variant
impl From<Region3int16> for Variant
source§fn from(value: Region3int16) -> Self
fn from(value: Region3int16) -> Self
Converts to this type from the input type.
source§impl From<SecurityCapabilities> for Variant
impl From<SecurityCapabilities> for Variant
source§fn from(value: SecurityCapabilities) -> Self
fn from(value: SecurityCapabilities) -> Self
Converts to this type from the input type.
source§fn from(value: SharedString) -> Self
fn from(value: SharedString) -> Self
Converts to this type from the input type.
source§impl From<Vector2int16> for Variant
impl From<Vector2int16> for Variant
source§fn from(value: Vector2int16) -> Self
fn from(value: Vector2int16) -> Self
Converts to this type from the input type.
source§impl From<Vector3int16> for Variant
impl From<Vector3int16> for Variant
source§fn from(value: Vector3int16) -> Self
fn from(value: Vector3int16) -> Self
Converts to this type from the input type.
source§impl PartialEq for Variant
impl PartialEq for Variant
impl StructuralPartialEq for Variant
Auto Trait Implementations§
impl RefUnwindSafe for Variant
impl Send for Variant
impl Sync for Variant
impl Unpin for Variant
impl UnwindSafe for Variant
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