<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def rest_equals(self, rest_object):
 """ Compare objects REST attributes """

        if not self.equals(rest_object):
            return False

        return self.to_dict() == rest_object.to_dict()