Spm::Core::PackageSystem Class Reference

#include <packageSystem.h>

List of all members.

Public Member Functions

 ~PackageSystem ()
ElementgetElement (const std::string &elementName) throw (UnknownElementException)
const std::list< Element * > & getElements ()
CategorygetCategory (const std::string &categoryName) throw (UnknownCategoryException)
const std::list< Category * > & getCategorys ()
void removeSet (const std::string &name) throw (UnknownElementException)
 Remove a Set.
void add (Element *package) throw (Util::NullPointerException, AlreadyExistingSetException)
 Add an Element.
void add (Category *category) throw (Util::NullPointerException, AlreadyExistingCategoryException)
 Add a Category.
void removeCategory (const std::string &name) throw (UnknownCategoryException)
 Remove a Category.
Plugin::InstallerInterfaceinstall (const std::string url, std::map< std::string, std::string > installerOptions) throw (AlreadyExistingBranchException, Plugin::NoPluginHandlerException, UnknownCategoryException, UnknownSetException, UnknownElementException, UnknownBranchException, NoRightException)
 Install a package.
void uninstall (const std::string &elementName, const std::string &branchName="") throw (UnknownElementException)
 Uninstall an Element.
BranchgetBranchOfFile (const std::string &file) throw (FileNotFoundException)
 Get the Branch of an installed file.
void checkDependency (const std::string &elementName) throw (DependencyException)
 Check Dependency of an element.
const std::string & user ()
const std::string & user () const

Static Public Member Functions

static boost::shared_ptr<
PackageSystem
create (const std::string &userName)
 Get a PackageSystem object.

Public Attributes

boost::signal< void(Element *)> signalNewElement )()
boost::signal< void(Category *)> signalNewCategory )()
boost::signal< void(Plugin::InstallerInterface *)> signalNewInstaller )()

Friends

class Store


Constructor & Destructor Documentation

Spm::Core::PackageSystem::~PackageSystem  ) 
 


Member Function Documentation

void Spm::Core::PackageSystem::add Category category  )  throw (Util::NullPointerException, AlreadyExistingCategoryException)
 

Add a Category.

Parameters:
category The Category to add

void Spm::Core::PackageSystem::add Element package  )  throw (Util::NullPointerException, AlreadyExistingSetException)
 

Add an Element.

Parameters:
package The Element to add

void Spm::Core::PackageSystem::checkDependency const std::string &  elementName  )  throw (DependencyException)
 

Check Dependency of an element.

Parameters:
elementName The name of the element to check

static boost::shared_ptr<PackageSystem> Spm::Core::PackageSystem::create const std::string &  userName  )  [static]
 

Get a PackageSystem object.

Parameters:
userName The user name of the wanted PackageSystem
Returns:
A PackageSystem object

Branch* Spm::Core::PackageSystem::getBranchOfFile const std::string &  file  )  throw (FileNotFoundException)
 

Get the Branch of an installed file.

Parameters:
file The file to look for
Returns:
The Branch of the file

Category* Spm::Core::PackageSystem::getCategory const std::string &  categoryName  )  throw (UnknownCategoryException)
 

Parameters:
categoryName The name of the wanted Category
Returns:
The wanted Category

const std::list<Category *>& Spm::Core::PackageSystem::getCategorys  ) 
 

Returns:
The list of Category

Element* Spm::Core::PackageSystem::getElement const std::string &  elementName  )  throw (UnknownElementException)
 

Parameters:
elementName The name of the wanted Element
Returns:
The wanted Element

const std::list<Element *>& Spm::Core::PackageSystem::getElements  ) 
 

Returns:
The list of Element

Plugin::InstallerInterface* Spm::Core::PackageSystem::install const std::string  url,
std::map< std::string, std::string >  installerOptions
throw (AlreadyExistingBranchException, Plugin::NoPluginHandlerException, UnknownCategoryException, UnknownSetException, UnknownElementException, UnknownBranchException, NoRightException)
 

Install a package.

Parameters:
url The URI of the package to install
installerOptions Option for the installer
Returns:
An installer handling the URI

void Spm::Core::PackageSystem::removeCategory const std::string &  name  )  throw (UnknownCategoryException)
 

Remove a Category.

Parameters:
name The name of Category to remove

void Spm::Core::PackageSystem::removeSet const std::string &  name  )  throw (UnknownElementException)
 

Remove a Set.

Parameters:
name The name of the Set to remove

void Spm::Core::PackageSystem::uninstall const std::string &  elementName,
const std::string &  branchName = ""
throw (UnknownElementException)
 

Uninstall an Element.

Parameters:
elementName The name of element to uninstall
branchName The name of the branch to uninstall (if blank, all Branch of the Element will be uninstalled)

const std::string& Spm::Core::PackageSystem::user  )  const [inline]
 

const std::string& Spm::Core::PackageSystem::user  )  [inline]
 


Friends And Related Function Documentation

friend class Store [friend]
 


Member Data Documentation

boost::signal<void (Category *)> Spm::Core::PackageSystem::signalNewCategory)()
 

boost::signal<void (Element *)> Spm::Core::PackageSystem::signalNewElement)()
 

boost::signal<void (Plugin::InstallerInterface *)> Spm::Core::PackageSystem::signalNewInstaller)()
 


The documentation for this class was generated from the following file:
Generated on Wed Jul 4 15:27:21 2007 for libSpm by  doxygen 1.4.6