Add static variants of trait property accessors and mutators, e.g. getMyPropertyFrom(traitsData) / setMyPropertyTo(traitsData)
Why
Currently trait view classes require construction around a TraitsDataPtr before property accessors/mutators can be used. This involves a copy-construction of the TraitsDataPtr. If the user only cares to query a particular property, then that copy-construction is a waste of resources.
Note that we already have static variants of imbue/isImbued, i.e. imbueTo/isImbuedTo, so doing similar for properties adds some functional parity.
What
Add
static
variants of trait property accessors and mutators, e.g.getMyPropertyFrom(traitsData)
/setMyPropertyTo(traitsData)
Why
Currently trait view classes require construction around a
TraitsDataPtr
before property accessors/mutators can be used. This involves a copy-construction of theTraitsDataPtr
. If the user only cares to query a particular property, then that copy-construction is a waste of resources.Note that we already have
static
variants ofimbue
/isImbued
, i.e.imbueTo
/isImbuedTo
, so doing similar for properties adds some functional parity.