Refactor codes to remove C++11 features

Use of C++11 features causes some problems when transplant codes, so use
other old techniques to replace them.
Fix a template error and change IOFrequencyUnit to struct

In Ubuntu, g++-4.6 does not recognize IOFrequencyUnit::DAYS when
IOFrequencyUnit is a enum, so I changed it to a struct with static
const int members.