Moved methods into classes