def ex_list_anti_affinity_rules(self, network=None, network_domain=None,
                                    node=None, filter_id=None,
                                    filter_state=None):
        not_none_arguments = [key
                              for key in (network, network_domain, node)
                              if key is not None]
        if len(not_none_arguments) != 1:
            raise ValueError("One and ONLY one of network, "
                             "network_domain, or node must be set")

        params = {}
        if network_domain is not None:
            params['networkDomainId'] = \
                self._network_domain_to_network_domain_id(network_domain)
        if network is not None:
            params['networkId'] = \
                self._network_to_network_id(network)
        if node is not None:
            params['serverId'] = \
                self._node_to_node_id(node)
        if filter_id is not None:
            params['id'] = filter_id
        if filter_state is not None:
            params['state'] = filter_state

        paged_result = self.connection.paginated_request_with_orgId_api_2(
            'server/antiAffinityRule',
            method='GET',
            params=params
        )

        rules = []
        for result in paged_result:
            rules.extend(self._to_anti_affinity_rules(result))
        return rules
Decorator for functions that require a supported third-party library.
dataset/ETHPy150Open apache/libcloud/libcloud/compute/drivers/dimensiondata.py/DimensionDataNodeDriver.ex_list_anti_affinity_rules--crossover with--dataset/ETHPy150Open chop-dbhi/serrano/serrano/conf/__init__.py/requires_dep