PropertyList

Trait PropertyList 

Source
pub trait PropertyList<E: Entity>: Copy + 'static {
    // Required methods
    fn validate() -> Result<(), IxaError>;
    fn contains_properties(property_type_ids: &[TypeId]) -> bool;
    fn set_values_for_new_entity(
        &self,
        entity_id: EntityId<E>,
        property_store: &mut PropertyStore<E>,
    );
    fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self;

    // Provided method
    fn contains_required_properties() -> bool { ... }
}

Required Methods§

Source

fn validate() -> Result<(), IxaError>

Validates that the properties are distinct. If not, returns an error describing the problematic properties.

Source

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Checks that this property list includes all properties in the given list.

Source

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Assigns the given entity the property values in self in the property_store. This method does NOT emit property change events, as it is called upon entity creation.

Source

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Gets the tuple of property values for the given entity.

Provided Methods§

Source

fn contains_required_properties() -> bool

Checks that this property list contains all required properties of the entity.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<E: Entity> PropertyList<E> for ()

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, _entity_id: EntityId<E>, _property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(_context: &Context, _entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>> PropertyList<E> for (P0, P1)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>> PropertyList<E> for (P0, P1, P2)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>> PropertyList<E> for (P0, P1, P2, P3)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>, P13: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12, P13)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>, P13: Property<E>, P14: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12, P13, P14)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>, P13: Property<E>, P14: Property<E>, P15: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12, P13, P14, P15)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>, P13: Property<E>, P14: Property<E>, P15: Property<E>, P16: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12, P13, P14, P15, P16)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>, P13: Property<E>, P14: Property<E>, P15: Property<E>, P16: Property<E>, P17: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12, P13, P14, P15, P16, P17)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>, P13: Property<E>, P14: Property<E>, P15: Property<E>, P16: Property<E>, P17: Property<E>, P18: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12, P13, P14, P15, P16, P17, P18)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P0: Property<E>, P1: Property<E>, P2: Property<E>, P3: Property<E>, P4: Property<E>, P5: Property<E>, P6: Property<E>, P7: Property<E>, P8: Property<E>, P9: Property<E>, P10: Property<E>, P11: Property<E>, P12: Property<E>, P13: Property<E>, P14: Property<E>, P15: Property<E>, P16: Property<E>, P17: Property<E>, P18: Property<E>, P19: Property<E>> PropertyList<E> for (P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12, P13, P14, P15, P16, P17, P18, P19)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Source§

impl<E: Entity, P: Property<E>> PropertyList<E> for (P,)

Source§

fn validate() -> Result<(), IxaError>

Source§

fn contains_properties(property_type_ids: &[TypeId]) -> bool

Source§

fn set_values_for_new_entity( &self, entity_id: EntityId<E>, property_store: &mut PropertyStore<E>, )

Source§

fn get_values_for_entity(context: &Context, entity_id: EntityId<E>) -> Self

Implementors§