def refresh(self):
if not self._item_path:<EOL><INDENT>raise AttributeError('<STR_LIT>' % self._type)<EOL><DEDENT>if not self.id:<EOL><INDENT>raise RedmineError('<STR_LIT>' % self._type)<EOL><DEDENT>try:<EOL><INDENT>self.save()<EOL><DEDENT>except:<EOL><INDENT>pass<EOL><DEDENT>target = self._item_path % self.id<EOL>json_data = self._redmine.get(target)<EOL>data = self._redmine.unwrap_json(self._type, json_data)<EOL>self._update_data(data=data)<EOL>
Refresh this item from data on the server.
        Will save any unsaved data first.