csbuild::main Class Reference

Frontend for schroot. More...

#include <csbuild-main.h>

Inheritance diagram for csbuild::main:

Inheritance graph
[legend]
Collaboration diagram for csbuild::main:

Collaboration graph
[legend]
List of all members.

Public Types

enum  error_code { DEVICE_NOTBLOCK, DEVICE_OWNED, DEVICE_RELEASE, DEVICE_STAT }
 Error codes. More...
typedef sbuild::custom_error<
error_code
error
 Exception type.

Public Member Functions

 main (options::ptr &options)
 The constructor.
virtual ~main ()
 The destructor.
virtual void action_build ()
 Build packages.
virtual int run_impl ()
 Run the program.

Public Attributes

options::ptr opts
 The program options.

Detailed Description

Frontend for schroot.

This class is used to "run" schroot.

Definition at line 35 of file csbuild-main.h.


Member Typedef Documentation

typedef sbuild::custom_error<error_code> csbuild::main::error

Exception type.

Definition at line 48 of file csbuild-main.h.


Member Enumeration Documentation

enum csbuild::main::error_code

Error codes.

Enumerator:
DEVICE_NOTBLOCK  File is not a block device.
DEVICE_OWNED  Failed to release device lock (lock held by PID).
DEVICE_RELEASE  Failed to release device lock.
DEVICE_STAT  Failed to stat device.

Definition at line 39 of file csbuild-main.h.


Constructor & Destructor Documentation

main::main ( options::ptr options  ) 

The constructor.

Parameters:
options the command-line options to use.

Definition at line 68 of file csbuild-main.cc.

main::~main (  )  [virtual]

The destructor.

Reimplemented from schroot_base::main.

Definition at line 79 of file csbuild-main.cc.


Member Function Documentation

void main::action_build (  )  [virtual]

Build packages.

Definition at line 84 of file csbuild-main.cc.

Referenced by run_impl().

Here is the caller graph for this function:

int main::run_impl (  )  [virtual]

Run the program.

Returns:
0 on success, 1 on failure or the exit status of the chroot command.

Implements schroot_base::main.

Definition at line 89 of file csbuild-main.cc.

References action_build(), csbuild::options::ACTION_BUILD, schroot_base::main::action_help(), schroot_base::options::ACTION_HELP, schroot_base::main::action_version(), and schroot_base::options::ACTION_VERSION.


Member Data Documentation

options::ptr csbuild::main::opts

The program options.

Definition at line 76 of file csbuild-main.h.


The documentation for this class was generated from the following files:
Generated on Sun Jul 8 21:24:27 2007 for schroot by  doxygen 1.5.2