Back to index

nordugrid-arc-nox  1.1.0~rc6
Public Types | Public Member Functions | Public Attributes
FileData Class Reference

#include <info_types.h>

Inheritance diagram for FileData:
Inheritance graph
[legend]
Collaboration diagram for FileData:
Collaboration graph
[legend]

List of all members.

Public Types

typedef std::list< FileData >
::iterator 
iterator

Public Member Functions

 FileData (void)
 FileData (const char *pfn_s, const char *lfn_s)
FileDataoperator= (const char *str)
bool operator== (const char *name)
bool operator== (const FileData &data)
bool has_lfn (void)

Public Attributes

std::string pfn
std::string lfn

Detailed Description

Definition at line 20 of file info_types.h.


Member Typedef Documentation

typedef std::list<FileData>::iterator FileData::iterator

Reimplemented in FileDataEx, and FileDataEx.

Definition at line 22 of file info_types.h.


Constructor & Destructor Documentation

FileData::FileData ( void  )

Definition at line 68 of file info_types.cpp.

                       {
}
FileData::FileData ( const char *  pfn_s,
const char *  lfn_s 
)

Definition at line 71 of file info_types.cpp.

                                                      {
  if(pfn_s) { pfn=pfn_s; } else { pfn.resize(0); };
  if(lfn_s) { lfn=lfn_s; } else { lfn.resize(0); };
}

Member Function Documentation

bool FileData::has_lfn ( void  )

Definition at line 102 of file info_types.cpp.

                           {
  return (lfn.find(':') != std::string::npos);
}
FileData & FileData::operator= ( const char *  str)

Definition at line 76 of file info_types.cpp.

                                              {
  pfn.resize(0); lfn.resize(0);
  int n=input_escaped_string(str,pfn);
  input_escaped_string(str+n,lfn);
  return *this;
}

Here is the call graph for this function:

bool FileData::operator== ( const char *  name)

Definition at line 94 of file info_types.cpp.

                                           {
  if(name == NULL) return false;
  if(name[0] == '/') ++name;
  const char* pfn_ = pfn.c_str();
  if(pfn_[0] == '/') ++pfn_;
  return (strcmp(pfn_,name) == 0);
}
bool FileData::operator== ( const FileData data)

Definition at line 83 of file info_types.cpp.

                                               {
  // pfn may contain leading slash. It must be striped
  // before comparison.
  const char* pfn_ = pfn.c_str();
  if(pfn_[0] == '/') ++pfn_;
  const char* dpfn_ = data.pfn.c_str();
  if(dpfn_[0] == '/') ++dpfn_;
  return (strcmp(pfn_,dpfn_) == 0);
  // return (pfn == data.pfn);
}

Member Data Documentation

std::string FileData::lfn

Definition at line 26 of file info_types.h.

std::string FileData::pfn

Definition at line 25 of file info_types.h.


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