Adds the relationships (e.g. "event" or "attachments") that should be expanded with the $expand parameter Important: The ApiComponent using this should know how to handle this relationships. eg: Message knows how to handle attachments, and event (if it's an EventMessage)
(self, *relationships)
| 683 | |
| 684 | @fluent |
| 685 | def expand(self, *relationships): |
| 686 | """ Adds the relationships (e.g. "event" or "attachments") |
| 687 | that should be expanded with the $expand parameter |
| 688 | Important: The ApiComponent using this should know how to handle this relationships. |
| 689 | eg: Message knows how to handle attachments, and event (if it's an EventMessage). |
| 690 | Important: When using expand on multi-value relationships a max of 20 items will be returned. |
| 691 | :param str relationships: the relationships tuple to expand. |
| 692 | :rtype: Query |
| 693 | """ |
| 694 | |
| 695 | for relationship in relationships: |
| 696 | if relationship == 'event': |
| 697 | relationship = '{}/event'.format(self.protocol.get_service_keyword('event_message_type')) |
| 698 | self._expands.add(relationship) |
| 699 | |
| 700 | return self |
| 701 | |
| 702 | @fluent |
| 703 | def search(self, text): |
no test coverage detected