Merge pull request #3793 from RosettaCommons/vmullig/enforce_generating_function_privacy
Trying to prevent some initialization functions for static const global data from being called from outside the intended context.
Currently, a developer could call these functions from anywhere. This causes two problems. First, it duplicates data that have already been generated and are available globally. Second, it creates possible memory leaks, since the data are allocated on the heap by raw pointer, and a developer will probably not think to call `delete[]` on them after finishing with his or her local copy.
By making the initialization functions into ordinary functions with no prototype outside of the context in which they are used, these functions can't be used for anything but initializing the static const data that they're supposed to initialize.
<b>Edit:</b> This pull request also fixes a memory leak in the ResidueCountFilter, caused by improperly calling one of the initialization functions.
Before merging, I need to do the following:
- [x] Check that the functions to get properties from strings and strings from properties are unit-tested.
- [x] Add some comments to those functions explaining how to use them.