def _get_owner(self, group_element): user_element = group_element.find('./owner/user') if user_element is None: return None user_reader = UserReader() user = user_reader.get_user(user_element) return user
def _get_users(self, parent, tag): users = set() user_elements = self._get_child_element(parent, tag) if user_elements is not None: for user in user_elements.findall('user'): user_reader = UserReader() user = user_reader.get_user(user) users.add(user) return users