def get_location(self): location = getattr(self.context.aq_base, 'location', None) if not location: return None else: if isinstance(location, unicode): return get_location(self.context) else: return location.to_object
def get_location(self, event_accessor): return get_location(event_accessor.context)
def get_location(self, occ): return get_location(occ)
def get_location(self, event): return get_location(event)
def get_location(self): return get_location(self.context)