Moved steps into a class, for abstraction.