Added some levels of abstraction and added new InputSources.