Refactored classes and modules associated with Tasks #2 and #4.