def __init__(self, partition_key_extractor, partition_map):
        """
        :param lambda partition_key_extractor:
            Returning the partition key from the document passed.
        :param dict partition_map:
            The dictionary of ranges mapped to their associated collection
        """
        if partition_key_extractor is None:
            raise ValueError("partition_key_extractor is None.")
        if partition_map is None:
            raise ValueError("partition_map is None.")

        self.partition_key_extractor = partition_key_extractor
        self.partition_map = partition_map
def __init__ ( self , partition_key_extractor , partition_map ) : if partition_key_extractor is None : raise ValueError ( "partition_key_extractor is None." ) if partition_map is None : raise ValueError ( "partition_map is None." ) self . partition_key_extractor = partition_key_extractor self . partition_map = partition_map
:param lambda partition_key_extractor:
            Returning the partition key from the document passed.
        :param dict partition_map:
            The dictionary of ranges mapped to their associated collection