def has_application(backend=None, has=(), capable=()):
 from ..app.backends import BACKEND_NAMES
 if (backend is None):
  for backend in BACKEND_NAMES:
   if has_backend(backend, has=has, capable=capable):
    good = True
    msg = backend
    break
  else:
   good = False
   msg = 'Requires application backend'
 else:
  (good, why) = has_backend(backend, has=has, capable=capable, out=['why_not'])
  if (not good):
   msg = ('Requires %s: %s' % (backend, why))
  else:
   msg = backend
 return (good, msg)

def has_application ( backend = None , has = ( ) , capable = ( ) ) : from . . app . backends import BACKEND_NAMES if ( backend is None ) : for backend in BACKEND_NAMES : if has_backend ( backend , has = has , capable = capable ) : good = True msg = backend break else : good = False msg = 'Requires application backend' else : ( good , why ) = has_backend ( backend , has = has , capable = capable , out = [ 'why_not' ] ) if ( not good ) : msg = ( 'Requires %s: %s' % ( backend , why ) ) else : msg = backend return ( good , msg )
determine if a suitable app backend exists .