renamed, divided logic into subpackages. creating interfaces to give less access to the client