Refactored Core Data elements to its own class for reusability