I'm working on implementing a kind of PlayListElement - the one that has a functionality to switch from child to child through its methods.
I consider the said feature is not currently implemented in SerialElement.
Is that possible (in the feature releases) to insert some intermediate child in inheritance chain or make a common ancestor or an interface at least to extract addChild, removeChild and other "child specific" methods from the current CompositeElement class.
The current problems are:
1) Composite element creates trait aggregator using private functions and constructor.
2) CompositeElement is coupled with CompositeMetadata
3) I can't subclass current implementation of CompositeElement in a legit way because the CompositionMode is an excluded class and that class is coupled with metadata and trait aggregator
For my playlist element both trait aggregator and composite metadata classes are not needed.
So I think it will be great if you could change a class hierarchy to something like that:
| OperatesChildrenClass | | addChild() | <- Only "child specific" methods | removeChild() | | | CompositeElement | <- Creates trait aggregator, CompositeMetadata | | SerialElement |
| OperatesChildrenClass |
| addChild() | <- Only "child specific" methods
| removeChild() |
| CompositeElement | <- Creates trait aggregator, CompositeMetadata
| SerialElement |
Using that approach I think can simplify various class factories, tracers etc
What do you think?