Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

mdfs::MFile Class Reference

A distributed file is not necessary stored locally LocalPath could point to the local file or be empty A local path could be different that the real path on the server since the file structure on the server could be simply stored in a DB, not on the HD By convention a directory is always followed by a slash (/). This help when we use a path as a unique key in a DB, so /mystuff (directory) and /mystuff (file) can each be a key because /mystuff (dir) must be rewritten /mystuff/ and is therefore different than /mystuff (file). More...

#include <MDistributedFileSystem.h>

List of all members.

Public Member Functions

 MFile ()
 MFile (const std::string &url)
 ~MFile ()
void SetURL (const std::string &url)
void SetType (const MFileType &t)
std::string GetURL () const
MFileType GetType () const
void Reset ()
std::string ExtractFileName () const
std::string ExtractFilePath () const

Public Attributes

std::string MD5
std::string LocalPath
 Local path (physical path).

MUtils::MDate Date
MUtils::MDate LastUpdate
unsigned long Size


Detailed Description

A distributed file is not necessary stored locally LocalPath could point to the local file or be empty A local path could be different that the real path on the server since the file structure on the server could be simply stored in a DB, not on the HD By convention a directory is always followed by a slash (/). This help when we use a path as a unique key in a DB, so /mystuff (directory) and /mystuff (file) can each be a key because /mystuff (dir) must be rewritten /mystuff/ and is therefore different than /mystuff (file).

Todo:
remember from what host it is coming? Kind of contradictory with the concept of "naming": -Location Transparency: the path name does not reveal the file location -Location Independance: files can be moved and al references to them continue to be valid


Constructor & Destructor Documentation

mdfs::MFile::MFile  )  [inline]
 

mdfs::MFile::MFile const std::string &  url  )  [inline]
 

mdfs::MFile::~MFile  )  [inline]
 


Member Function Documentation

string MFile::ExtractFileName  )  const
 

string MFile::ExtractFilePath  )  const
 

MFileType mdfs::MFile::GetType  )  const [inline]
 

std::string mdfs::MFile::GetURL  )  const [inline]
 

void mdfs::MFile::Reset  )  [inline]
 

void MFile::SetType const MFileType t  ) 
 

also verify the trailing / if it is a dir

void MFile::SetURL const std::string &  url  ) 
 


Member Data Documentation

MUtils::MDate mdfs::MFile::Date
 

MUtils::MDate mdfs::MFile::LastUpdate
 

std::string mdfs::MFile::LocalPath
 

Local path (physical path).

std::string mdfs::MFile::MD5
 

unsigned long mdfs::MFile::Size
 


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


MDFS SourceForge project page and download

SourceForge.net Logo

Generated on Sat Jan 3 03:14:20 2004 for MDFS by doxygen1.3.5