Skip to main content

IAnimatedServerObject

Trait IAnimatedServerObject 

Source
pub trait IAnimatedServerObject: IServerObject + IServerAnimatedPropertyHost {
    // Required methods
    fn server_object(&self) -> &ServerObject;
    fn as_server_object_dyn(&self) -> &dyn IServerObject;

    // Provided methods
    fn get_composition_property(
        &self,
        _field_name: &str,
    ) -> Option<&'static CompositionProperty> { ... }
    fn read_property_variant(
        &self,
        property: &'static CompositionProperty,
    ) -> ExpressionVariant { ... }
    fn write_property_variant(
        &self,
        property: &'static CompositionProperty,
        value: ExpressionVariant,
    ) { ... }
}
Expand description

A server object that supports animated properties: what upstream’s abstract ServerObject is to its subclasses.

A class “derives” from ServerObject by embedding a ServerObject and implementing this trait; the embedded part reaches the class through it.

Required Methods§

Source

fn server_object(&self) -> &ServerObject

The embedded ServerObject part.

Source

fn as_server_object_dyn(&self) -> &dyn IServerObject

The object as the base contract (an explicit upcast).

Provided Methods§

Source

fn get_composition_property( &self, _field_name: &str, ) -> Option<&'static CompositionProperty>

The composition property with the given name, if the class has one.

Source

fn read_property_variant( &self, property: &'static CompositionProperty, ) -> ExpressionVariant

Reads a property of the object as a variant. The default reads the field through CompositionProperty::get_variant; an object with dynamic properties (a property set) reads its own storage.

Source

fn write_property_variant( &self, property: &'static CompositionProperty, value: ExpressionVariant, )

Writes a variant into a property of the object without notification (what an animation does with the value it evaluated). The default writes the field through CompositionProperty::set_variant; an object with dynamic properties writes its own storage.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl IAnimatedServerObject for ServerAmbientLight

Source§

impl IAnimatedServerObject for ServerCompositionBackdropBrush

Source§

impl IAnimatedServerObject for ServerCompositionBitmapCache

Source§

impl IAnimatedServerObject for ServerCompositionConicGradientBrush

Source§

impl IAnimatedServerObject for ServerCompositionContainerShape

Source§

impl IAnimatedServerObject for ServerCompositionEffectBrush

Source§

impl IAnimatedServerObject for ServerCompositionEllipseGeometry

Source§

impl IAnimatedServerObject for ServerCompositionGradientStop

Source§

impl IAnimatedServerObject for ServerCompositionHostBackdropBrush

Source§

impl IAnimatedServerObject for ServerCompositionLineGeometry

Source§

impl IAnimatedServerObject for ServerCompositionLinearGradientBrush

Source§

impl IAnimatedServerObject for ServerCompositionMaskBrush

Source§

impl IAnimatedServerObject for ServerCompositionNineGridBrush

Source§

impl IAnimatedServerObject for ServerCompositionPathGeometry

Source§

impl IAnimatedServerObject for ServerCompositionPropertySet

Source§

impl IAnimatedServerObject for ServerCompositionRadialGradientBrush

Source§

impl IAnimatedServerObject for ServerCompositionRectangleGeometry

Source§

impl IAnimatedServerObject for ServerCompositionRoundedRectangleGeometry

Source§

impl IAnimatedServerObject for ServerCompositionShapeCollection

Source§

impl IAnimatedServerObject for ServerCompositionSolidColorBrush

Source§

impl IAnimatedServerObject for ServerCompositionSpriteShape

Source§

impl IAnimatedServerObject for ServerCompositionSurfaceBrush

Source§

impl IAnimatedServerObject for ServerCompositionTarget

Source§

impl IAnimatedServerObject for ServerCompositionViewBox

Source§

impl IAnimatedServerObject for ServerCompositionVisual

Source§

impl IAnimatedServerObject for ServerCompositionVisualCollection

Source§

impl IAnimatedServerObject for ServerCompositionVisualSurface

Source§

impl IAnimatedServerObject for ServerDistantLight

Source§

impl IAnimatedServerObject for ServerDropShadow

Source§

impl IAnimatedServerObject for ServerGeometricClip

Source§

impl IAnimatedServerObject for ServerInsetClip

Source§

impl IAnimatedServerObject for ServerPointLight

Source§

impl IAnimatedServerObject for ServerRectangleClip

Source§

impl IAnimatedServerObject for ServerSpotLight

Source§

impl IAnimatedServerObject for ServerVisualUnorderedCollection