macro_rules! impl_derived_property {
(
$name:ident,
$entity:ident,
[$($dependency:ident),*]
$(, [$($global_dependency:ident),*])?,
|$($param:ident),+| $derive_fn:expr
$(, $($extra:tt)+)*
) => { ... };
(
@construct_compute_fn
$entity:ident,
[$($dependency:ident),*],
[$($global_dependency:ident),*],
|$($param:ident),+| $derive_fn:expr
) => { ... };
(@unwrap_or $value:expr, $_default:expr) => { ... };
(@unwrap_or, $default:expr) => { ... };
(
@with_option_display_default
$name:ident,
$entity:ident,
[$($dependency:ident),*],
[$($global_dependency:ident),*],
|$($param:ident),+| $derive_fn:expr
$(, default_const = $default_const:expr)?
$(, display_impl = $display_impl:expr)?
$(, canonical_value = $canonical_value:ty)?
$(, make_canonical = $make_canonical:expr)?
$(, make_uncanonical = $make_uncanonical:expr)?
$(, index_id_fn = $index_id_fn:expr)?
$(, collect_deps_fn = $collect_deps_fn:expr)?
$(, ctor_registration = $ctor_registration:expr)?
) => { ... };
}Expand description
Implements the Property trait for an existing type as a derived property.
Accepts the same parameters as define_derived_property!, except the first parameter is the name of a
type assumed to already be declared rather than a type declaration. This is the derived property equivalent
of impl_property!. It calls impl_property! with the appropriate derived property parameters.