Clarify nature of missing modifier stack object references, AddModifierStack->AddModifierStacks
Apropos of no preexisting issue, for your consideration:
When aggregating ModifierStack objects for VectorLayerVisualizer, it cannot be assumed that all serialized list entries are non-null, as they come from the Editor. Thus, it is benefitial to clarify the reason NullReferenceExceptions are given when iterating over their collection.
Additionally, the AddModifierStack method may add multiple ModifierStack objects, implying that it should be named "AddModifierStacks". Also, it does not need a List to function.
If you have different ideas for the future of AddModifierStack, please close this pull request, and consider the NullReferenceException modification for future scenarios where serialized data is referenced via LINQ or otherwise.
Description of changes
VectorLayerVisualizerObject
- LINQ ModifierStackObject aggregating expression tests if stack is null, and if it is, it raises an exception with an explanation of what is null
VectorLayerVisualizer, IVectorLayerVisualizer
- AddModifierStack signature changed to
AddModifierStacks(IEnumerable<ModifierStack> stacks)
Reviewers
@brnkhy