Refactored Resource class. Replaced namedTuple with a member Position class.