parameters: (full_router_path)
return_statement: return import_class(full_router_path)
docstring: Loads a router for choosing which connection to use.
  
      Requires a ``full_router_path``. It should be a string resembling a Python
      import path, pointing to a ``BaseRouter`` subclass. The built-in options
      available include::
  
        * haystack.routers.DefaultRouter
  
      If you've implemented a custom backend, you can provide the path to
      your backend & matching ``Engine`` class. For example::
  
        ``myapp.search_routers.MasterSlaveRouter``
docstring_summary: Loads a router for choosing which connection to use.
docstring_tokens: Loads a router for choosing which connection to use .
function: def load_router(full_router_path):
      """
      Loads a router for choosing which connection to use.
  
      Requires a ``full_router_path``. It should be a string resembling a Python
      import path, pointing to a ``BaseRouter`` subclass. The built-in options
      available include::
  
        * haystack.routers.DefaultRouter
  
      If you've implemented a custom backend, you can provide the path to
      your backend & matching ``Engine`` class. For example::
  
        ``myapp.search_routers.MasterSlaveRouter``
  
      """
      path_bits = full_router_path.split('.')
  
      if len(path_bits) < 2:
          raise ImproperlyConfigured("The provided router '%s' is not a complete Python path to a BaseRouter subclass." % full_router_path)
  
      return import_class(full_router_path)
function_tokens: def load_router ( full_router_path ) : path_bits = full_router_path . split ( '.' ) if len ( path_bits ) < 2 : raise ImproperlyConfigured ( "The provided router '%s' is not a complete Python path to a BaseRouter subclass." % full_router_path ) return import_class ( full_router_path )