ldas-tools-al  2.6.5
Classes | Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
LDASTools::AL::Directory Class Reference

Read the contents of a directory. More...

#include <Directory.hh>

Classes

class  Internals
 

Public Types

enum  mode_type {
  MODE_BLOCKING, MODE_NON_BLOCKING, MODE_BLOCKING, MODE_NON_BLOCKING,
  MODE_BLOCKING, MODE_NON_BLOCKING
}
 Enumerated type specifying the blocking mode. More...
 
enum  mode_type {
  MODE_BLOCKING, MODE_NON_BLOCKING, MODE_BLOCKING, MODE_NON_BLOCKING,
  MODE_BLOCKING, MODE_NON_BLOCKING
}
 Enumerated type specifying the blocking mode. More...
 
enum  mode_type {
  MODE_BLOCKING, MODE_NON_BLOCKING, MODE_BLOCKING, MODE_NON_BLOCKING,
  MODE_BLOCKING, MODE_NON_BLOCKING
}
 Enumerated type specifying the blocking mode. More...
 
typedef std::list< std::string > block_read_type
 
typedef boost::shared_ptr< Internalsvalue_type
 
typedef std::list< std::string > block_read_type
 
typedef boost::shared_ptr< Internalsvalue_type
 
typedef std::list< std::string > block_read_type
 
typedef boost::shared_ptr< Internalsvalue_type
 

Public Member Functions

 Directory (const std::string &DirName, bool OpenDirectory=true)
 Constructor. More...
 
 ~Directory ()
 Destructor. More...
 
void Close ()
 Close the directory. More...
 
const char * EntryName () const
 
int Fd () const
 
const std::string & Name () const
 
mode_type Mode () const
 
void Mode (mode_type Mode)
 
bool Next ()
 
void Next (block_read_type &Entries)
 
void Open ()
 
 Directory (const std::string &DirName, bool OpenDirectory=true)
 Constructor. More...
 
 ~Directory ()
 Destructor. More...
 
void Close ()
 Close the directory. More...
 
const char * EntryName () const
 
int Fd () const
 
const std::string & Name () const
 
mode_type Mode () const
 
void Mode (mode_type Mode)
 
bool Next ()
 
void Next (block_read_type &Entries)
 
void Open ()
 
 Directory (const std::string &DirName, bool OpenDirectory=true)
 Constructor. More...
 
 ~Directory ()
 Destructor. More...
 
void Close ()
 Close the directory. More...
 
const char * EntryName () const
 
int Fd () const
 
const std::string & Name () const
 
mode_type Mode () const
 
void Mode (mode_type Mode)
 
bool Next ()
 
void Next (block_read_type &Entries)
 
void Open ()
 

Static Public Member Functions

static int Timeout ()
 Retrieve the number of seconds any one of the calls should take. More...
 
static void Timeout (int Value)
 Specify the number of seconds any one of the calls should take. More...
 
static int Timeout ()
 Retrieve the number of seconds any one of the calls should take. More...
 
static void Timeout (int Value)
 Specify the number of seconds any one of the calls should take. More...
 
static int Timeout ()
 Retrieve the number of seconds any one of the calls should take. More...
 
static void Timeout (int Value)
 Specify the number of seconds any one of the calls should take. More...
 

Private Member Functions

void eval_request (const int Request)
 
void eval_request (const int Request)
 
void eval_request (const int Request)
 

Private Attributes

value_type m_internals
 
mode_type m_blocking_mode
 

Detailed Description

Read the contents of a directory.

This provides a system independent interface to reading the the contents of a directory. It can operate in a blocking or non-blocking mode. By default, it operates in non-blocking mode.

Member Typedef Documentation

◆ block_read_type [1/3]

typedef std::list< std::string > LDASTools::AL::Directory::block_read_type

◆ block_read_type [2/3]

typedef std::list< std::string > LDASTools::AL::Directory::block_read_type

◆ block_read_type [3/3]

typedef std::list< std::string > LDASTools::AL::Directory::block_read_type

◆ value_type [1/3]

typedef boost::shared_ptr< Internals > LDASTools::AL::Directory::value_type

◆ value_type [2/3]

typedef boost::shared_ptr< Internals > LDASTools::AL::Directory::value_type

◆ value_type [3/3]

typedef boost::shared_ptr< Internals > LDASTools::AL::Directory::value_type

Member Enumeration Documentation

◆ mode_type [1/3]

Enumerated type specifying the blocking mode.

This is used by the Mode method to specify the blocking mode the subsequent calls should operate in.

Enumerator
MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

◆ mode_type [2/3]

Enumerated type specifying the blocking mode.

This is used by the Mode method to specify the blocking mode the subsequent calls should operate in.

Enumerator
MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

◆ mode_type [3/3]

Enumerated type specifying the blocking mode.

This is used by the Mode method to specify the blocking mode the subsequent calls should operate in.

Enumerator
MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

MODE_BLOCKING 

Blocking mode.

When in blocking mode, calls made will operate in the current thread and return when the system call returns.

MODE_NON_BLOCKING 

Non blocking mode.

When in non-blocking mode, calls are done in a thread and given a specific amount of time in which to return. If they do not return within the alotted time, then an exception is thrown.

Constructor & Destructor Documentation

◆ Directory() [1/3]

LDASTools::AL::Directory::Directory ( const std::string &  DirName,
bool  OpenDirectory = true 
)

Constructor.

Construct a new instance of this object.

◆ ~Directory() [1/3]

LDASTools::AL::Directory::~Directory ( )

Destructor.

Release resources back to the system.

◆ Directory() [2/3]

LDASTools::AL::Directory::Directory ( const std::string &  DirName,
bool  OpenDirectory = true 
)

Constructor.

Construct a new instance of this object.

◆ ~Directory() [2/3]

LDASTools::AL::Directory::~Directory ( )

Destructor.

Release resources back to the system.

◆ Directory() [3/3]

LDASTools::AL::Directory::Directory ( const std::string &  DirName,
bool  OpenDirectory = true 
)

Constructor.

Construct a new instance of this object.

◆ ~Directory() [3/3]

LDASTools::AL::Directory::~Directory ( )

Destructor.

Release resources back to the system.

Member Function Documentation

◆ Close() [1/3]

void LDASTools::AL::Directory::Close ( )

Close the directory.

◆ Close() [2/3]

void LDASTools::AL::Directory::Close ( )

Close the directory.

◆ Close() [3/3]

void LDASTools::AL::Directory::Close ( )

Close the directory.

◆ EntryName() [1/3]

const char * LDASTools::AL::Directory::EntryName ( ) const

◆ EntryName() [2/3]

const char* LDASTools::AL::Directory::EntryName ( ) const

◆ EntryName() [3/3]

const char* LDASTools::AL::Directory::EntryName ( ) const

◆ eval_request() [1/3]

void LDASTools::AL::Directory::eval_request ( const int  Request)
private

◆ eval_request() [2/3]

void LDASTools::AL::Directory::eval_request ( const int  Request)
inlineprivate

◆ eval_request() [3/3]

void LDASTools::AL::Directory::eval_request ( const int  Request)
private

◆ Fd() [1/3]

int LDASTools::AL::Directory::Fd ( ) const

◆ Fd() [2/3]

int LDASTools::AL::Directory::Fd ( ) const

◆ Fd() [3/3]

int LDASTools::AL::Directory::Fd ( ) const

◆ Mode() [1/6]

mode_type LDASTools::AL::Directory::Mode ( ) const

◆ Mode() [2/6]

Directory::mode_type LDASTools::AL::Directory::Mode ( ) const
inline

◆ Mode() [3/6]

mode_type LDASTools::AL::Directory::Mode ( ) const

◆ Mode() [4/6]

void LDASTools::AL::Directory::Mode ( mode_type  Mode)

◆ Mode() [5/6]

void LDASTools::AL::Directory::Mode ( mode_type  Mode)
inline

◆ Mode() [6/6]

void LDASTools::AL::Directory::Mode ( mode_type  Mode)

◆ Name() [1/3]

const std::string & LDASTools::AL::Directory::Name ( ) const

◆ Name() [2/3]

const std::string& LDASTools::AL::Directory::Name ( ) const

◆ Name() [3/3]

const std::string& LDASTools::AL::Directory::Name ( ) const

◆ Next() [1/6]

bool LDASTools::AL::Directory::Next ( )

Retrieve the next entry. returns true if a valid entry was found, false otherwise

◆ Next() [2/6]

bool LDASTools::AL::Directory::Next ( )

Retrieve the next entry. returns true if a valid entry was found, false otherwise

◆ Next() [3/6]

bool LDASTools::AL::Directory::Next ( )

Retrieve the next entry. returns true if a valid entry was found, false otherwise

◆ Next() [4/6]

void LDASTools::AL::Directory::Next ( block_read_type Entries)

◆ Next() [5/6]

void LDASTools::AL::Directory::Next ( block_read_type Entries)

◆ Next() [6/6]

void LDASTools::AL::Directory::Next ( block_read_type Entries)

◆ Open() [1/3]

void LDASTools::AL::Directory::Open ( )

◆ Open() [2/3]

void LDASTools::AL::Directory::Open ( )

◆ Open() [3/3]

void LDASTools::AL::Directory::Open ( )

◆ Timeout() [1/6]

static int LDASTools::AL::Directory::Timeout ( )
static

Retrieve the number of seconds any one of the calls should take.

◆ Timeout() [2/6]

static int LDASTools::AL::Directory::Timeout ( )
static

Retrieve the number of seconds any one of the calls should take.

◆ Timeout() [3/6]

int LDASTools::AL::Directory::Timeout ( )
static

Retrieve the number of seconds any one of the calls should take.

◆ Timeout() [4/6]

static void LDASTools::AL::Directory::Timeout ( int  Value)
static

Specify the number of seconds any one of the calls should take.

◆ Timeout() [5/6]

static void LDASTools::AL::Directory::Timeout ( int  Value)
static

Specify the number of seconds any one of the calls should take.

◆ Timeout() [6/6]

void LDASTools::AL::Directory::Timeout ( int  Value)
static

Specify the number of seconds any one of the calls should take.

Member Data Documentation

◆ m_blocking_mode

mode_type LDASTools::AL::Directory::m_blocking_mode
private

◆ m_internals

value_type LDASTools::AL::Directory::m_internals
private

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