(self, value)
Restore from pickling.
Restore from pickling.
Restore from pickling .
def __setstate__(self, value):
        """Restore from pickling."""
        self.__mode = value['mode']
        self.__mongos_mode = _MONGOS_MODES[self.__mode]
        self.__tag_sets = _validate_tag_sets(value['tag_sets'])
        self.__max_staleness = _validate_max_staleness(value['max_staleness'])
def __setstate__ ( self , value ) : self . __mode = value [ 'mode' ] self . __mongos_mode = _MONGOS_MODES [ self . __mode ] self . __tag_sets = _validate_tag_sets ( value [ 'tag_sets' ] ) self . __max_staleness = _validate_max_staleness ( value [ 'max_staleness' ] )