Statement of the problem:
NDArrays cannot be modified by plugins because a pointer is passed to each plugin
Many plugins only need to modify the attribute list, not the NDArray. But they must currently copy the entire NDArray to modify the attribute list.
Make a new container class:
NDArrayContaininer {
NDArray *pArray;
NDAttributeList *pAttributeList;
}
Container is now what gets passed to plugins. NDArray still cannot be modified. But pAttributeList can be copied and modified.
Plugin passes new container to other plugins down the chain.
Statement of the problem:
NDArrays cannot be modified by plugins because a pointer is passed to each plugin
Many plugins only need to modify the attribute list, not the NDArray. But they must currently copy the entire NDArray to modify the attribute list.
Make a new container class:
NDArrayContaininer {
NDArray *pArray;
NDAttributeList *pAttributeList;
}
Container is now what gets passed to plugins. NDArray still cannot be modified. But pAttributeList can be copied and modified.
Plugin passes new container to other plugins down the chain.