Moved classes into lib