Split option code away from SelectionCollection.
authorTeemu Murtola <teemu.murtola@gmail.com>
Fri, 18 May 2012 08:32:56 +0000 (11:32 +0300)
committerTeemu Murtola <teemu.murtola@gmail.com>
Fri, 18 May 2012 09:46:34 +0000 (12:46 +0300)
commit896cf4e4c27758e3371f66fa5552fe004613b02f
tree6d687f74128e510aba80d03d3b50d55a1e5e1a12
parent1698224bd6251c2b0ece0fd375c0c095ce5eddb8
Split option code away from SelectionCollection.

Move code required for selection option implementation from
SelectionCollection to a separate SelectionOptionManager class.
Simplified the selection request handling code in the process, but
otherwise this commit mainly moves code around without changing any
functionality (except for small changes required to use the new class
in code using the selections).

This makes the responsibilities in the code clearer, since
SelectionCollection is now completely independent of any options
implementation.  It also simplifies the involved classes, since
the options handling (which will become even more involved with #656)
no longer complicates the core of the selection module.

Related to #656.

Change-Id: Iac24a2f9392c8cc2421edef3f212ddb462e864b3
16 files changed:
src/gromacs/commandline/tests/cmdlinehelpwriter.cpp
src/gromacs/selection.h
src/gromacs/selection/CMakeLists.txt
src/gromacs/selection/selectioncollection-impl.h
src/gromacs/selection/selectioncollection.cpp
src/gromacs/selection/selectioncollection.h
src/gromacs/selection/selectionfileoption.h
src/gromacs/selection/selectionfileoptioninfo.h
src/gromacs/selection/selectionfileoptionstorage.h
src/gromacs/selection/selectionoption.cpp
src/gromacs/selection/selectionoptioninfo.h
src/gromacs/selection/selectionoptionmanager.cpp [new file with mode: 0644]
src/gromacs/selection/selectionoptionmanager.h [new file with mode: 0644]
src/gromacs/selection/selectionoptionstorage.h
src/gromacs/selection/tests/selectionoption.cpp
src/gromacs/trajectoryanalysis/cmdlinerunner.cpp