(self, namespace_tuple)
return False
Helper for _namespace_requested. Supports limited wildcards
Helper for _namespace_requested. Supports limited wildcards
Helper for _namespace_requested . Supports limited wildcards
def _tuple_requested(self, namespace_tuple):
        """Helper for _namespace_requested. Supports limited wildcards"""
        if not isinstance(namespace_tuple[0], unicode):
            encoded_db = unicode(namespace_tuple[0])
        else:
            encoded_db = namespace_tuple[0]
        if not isinstance(namespace_tuple[1], unicode):
            encoded_coll = unicode(namespace_tuple[1])
        else:
            encoded_coll = namespace_tuple[1]

        if namespace_tuple is None:
            return False
        elif len(self._requested_namespaces) is 0:
            return True
        for requested_namespace in self._requested_namespaces:
            if  ((((requested_namespace[0]) == u'*') or
                 (encoded_db == requested_namespace[0])) and
                (((requested_namespace[1]) == u'*') or
                 (encoded_coll == requested_namespace[1]))):
                return True
        return False
def _tuple_requested ( self , namespace_tuple ) : if not isinstance ( namespace_tuple [ 0 ] , unicode ) : encoded_db = unicode ( namespace_tuple [ 0 ] ) else : encoded_db = namespace_tuple [ 0 ] if not isinstance ( namespace_tuple [ 1 ] , unicode ) : encoded_coll = unicode ( namespace_tuple [ 1 ] ) else : encoded_coll = namespace_tuple [ 1 ] if namespace_tuple is None : return False elif len ( self . _requested_namespaces ) is 0 : return True for requested_namespace in self . _requested_namespaces : if ( ( ( ( requested_namespace [ 0 ] ) == u'*' ) or ( encoded_db == requested_namespace [ 0 ] ) ) and ( ( ( requested_namespace [ 1 ] ) == u'*' ) or ( encoded_coll == requested_namespace [ 1 ] ) ) ) : return True return False