(cls, backend_type, domain=None)
return BackendMap(catchall_backend_id, backend_map)
backend_type - SQLMobileBackend.SMS or SQLMobileBackend.IVR
        domain - the domain for which to retrieve the backend map, otherwise if left None
                 the global backend map will be returned.
        Returns a BackendMap
backend_type - SQLMobileBackend.SMS or SQLMobileBackend.IVR
        domain - the domain for which to retrieve the backend map, otherwise if left None
                 the global backend map will be returned.
        Returns a BackendMap
backend_type - SQLMobileBackend . SMS or SQLMobileBackend . IVR domain - the domain for which to retrieve the backend map otherwise if left None the global backend map will be returned . Returns a BackendMap
def get_prefix_to_backend_map(cls, backend_type, domain=None):
        """
        backend_type - SQLMobileBackend.SMS or SQLMobileBackend.IVR
        domain - the domain for which to retrieve the backend map, otherwise if left None
                 the global backend map will be returned.
        Returns a BackendMap
        """
        if domain:
            filter_args = {'backend_type': backend_type, 'is_global': False, 'domain': domain}
        else:
            filter_args = {'backend_type': backend_type, 'is_global': True}

        catchall_backend_id = None
        backend_map = {}
        for instance in cls.objects.filter(**filter_args):
            if instance.prefix == '*':
                catchall_backend_id = instance.backend_id
            else:
                backend_map[instance.prefix] = instance.backend_id

        return BackendMap(catchall_backend_id, backend_map)
def get_prefix_to_backend_map ( cls , backend_type , domain = None ) : if domain : filter_args = { 'backend_type' : backend_type , 'is_global' : False , 'domain' : domain } else : filter_args = { 'backend_type' : backend_type , 'is_global' : True } catchall_backend_id = None backend_map = { } for instance in cls . objects . filter ( * * filter_args ) : if instance . prefix == '*' : catchall_backend_id = instance . backend_id else : backend_map [ instance . prefix ] = instance . backend_id return BackendMap ( catchall_backend_id , backend_map )