Spm::Util::Compressed Class Reference

Base class for archive manipluation. More...

#include <compressed.h>

Inheritance diagram for Spm::Util::Compressed:

Spm::Util::Directory Spm::Util::TarFile Spm::Util::ZipFile List of all members.

Public Member Functions

virtual ~Compressed ()
virtual bool uncompress (const boost::filesystem::path &dest)=0
const boost::filesystem::path & getName ()
bool have (const std::string &file)
 Check if a file is in the archive.
virtual bool extract (const std::string &file, const boost::filesystem::path &to)=0
std::string getSubDir ()
const std::string & getExactName (const std::string &file) throw (FileNotFoundException)

Protected Member Functions

 Compressed ()
 Compressed (const boost::filesystem::path &fileName)

Protected Attributes

boost::filesystem::path __file
std::list< std::string > files

Detailed Description

Base class for archive manipluation.


Constructor & Destructor Documentation

Spm::Util::Compressed::Compressed  )  [inline, protected]
 

Spm::Util::Compressed::Compressed const boost::filesystem::path &  fileName  )  [protected]
 

virtual Spm::Util::Compressed::~Compressed  )  [inline, virtual]
 


Member Function Documentation

virtual bool Spm::Util::Compressed::extract const std::string &  file,
const boost::filesystem::path &  to
[pure virtual]
 

Parameters:
file The file to extract
to Where the file will be extracted

Implemented in Spm::Util::Directory, Spm::Util::TarFile, and Spm::Util::ZipFile.

const std::string& Spm::Util::Compressed::getExactName const std::string &  file  )  throw (FileNotFoundException)
 

Parameters:
file The searched file
Returns:
The exact name of an element of the compressed archive

const boost::filesystem::path& Spm::Util::Compressed::getName  ) 
 

Returns:
the name of the compressed file

std::string Spm::Util::Compressed::getSubDir  ) 
 

Returns:
the subdir which contains all files of the archive

bool Spm::Util::Compressed::have const std::string &  file  ) 
 

Check if a file is in the archive.

Parameters:
file The file to search
Returns:
true if the file is in the archive, false otherwise

virtual bool Spm::Util::Compressed::uncompress const boost::filesystem::path &  dest  )  [pure virtual]
 

Parameters:
dest The directory where The archive will be uncompressed

Implemented in Spm::Util::Directory, Spm::Util::TarFile, and Spm::Util::ZipFile.


Member Data Documentation

boost::filesystem::path Spm::Util::Compressed::__file [protected]
 

std::list<std::string> Spm::Util::Compressed::files [protected]
 


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