Fixed interdependencies, implemented formatting

When a circular reference occurs, a warning message is displayed.
Formattting now works, needs to be tested. Switched methods used
internally from public to private in the Command class. To test private
methods, test the public methods they are called in rather than changing
private methods to public.