Ravel Python API Reference
A Database-Defined Network Controller
Public Member Functions | List of all members
ravel.app.Application Class Reference

A Ravel application. More...

Inherits object.

Public Member Functions

def __init__
 name: the name of the application
 
def link
 Link a resource or implementation file to the application. More...
 
def is_loadable
 
def load
 Load the application from the specified database. More...
 
def unload
 Unload the application from the specified database. More...
 
def init
 Initialize the application without loading it into the database. More...
 
def cmd
 Execute a command in the application's sub-shell. More...
 

Detailed Description

A Ravel application.

In Ravel, an application contains a SQL implementation and, optionally, a sub-shell implemented in Python to monitor and control the application. Application sub-shells are accesible from the main Ravel CLI by loading the application and typing its name or shortcut.

Member Function Documentation

def ravel.app.Application.cmd (   self,
  line 
)

Execute a command in the application's sub-shell.

If an empty command is passed, start the application's sub-shell in a cmdloop

Parameters
linea command in the application's sub-shell, or an empty string
def ravel.app.Application.init (   self,
  db,
  env 
)

Initialize the application without loading it into the database.

Parameters
dba ravel.db.RavelDb instance to be passed to the application's sub-shell
enva ravel.env.Environment instance of the CLI's executing environment to be passed to the application's sub-shell
def ravel.app.Application.is_loadable (   self)
Returns
true if the application's Python component (it's sub-shell) can be imported and instantiated
def ravel.app.Application.link (   self,
  filename 
)

Link a resource or implementation file to the application.

Parameters
filenamepath to the file containing an application's resource
def ravel.app.Application.load (   self,
  db 
)

Load the application from the specified database.

Parameters
dba ravel.db.RavelDb instance into which the application will be loaded
def ravel.app.Application.unload (   self,
  db 
)

Unload the application from the specified database.

Parameters
dba ravel.db.RavelDb instance containing the application

The documentation for this class was generated from the following file: