1 #ifndef __JLANG__JFILEDESCRIPTORMASK__ 
    2 #define __JLANG__JFILEDESCRIPTORMASK__ 
    4 #include <sys/select.h> 
   16 namespace JPP { 
using namespace JLANG; }
 
   80     const fd_set* 
get()
 const 
   82       return static_cast<const fd_set*
>(
this);
 
   93       return static_cast<fd_set*
>(
this);
 
  126     void reset(
const bool option = 
true)
 
  155     void set(
const int file_descriptor)
 
  157       if (!
has(file_descriptor)) {
 
  159         FD_SET(file_descriptor, 
get());
 
  186     void reset(
const int file_descriptor)
 
  188       if (
has(file_descriptor)) {
 
  190         FD_CLR(file_descriptor, 
get());
 
  218     bool has(
const int file_descriptor)
 const 
  220       return FD_ISSET(file_descriptor, 
get());
 
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
 
The JAbstractFile class encapsulates the c-style file descriptor.
 
int getFileDescriptor() const
Get file descriptor.
 
Auxiliary class for method select.
 
fd_set * get()
Get pointer to mask.
 
bool out_avail(JTimeval timeout=JTimeval::min())
Check availability of output.
 
static const int MAXIMUM_FILE_DESCRIPTOR
 
void reset(const JAbstractFile &file)
Reset file.
 
void set(const int file_descriptor)
Set file descriptor.
 
JFileDescriptorMask(const int file_descriptor)
Constructor.
 
JFileDescriptorMask()
Default constructor.
 
int maximum_file_descriptor
 
const fd_set * get() const
Get pointer to mask.
 
void reset(const bool option=true)
Reset mask.
 
bool has(const JAbstractFile &file) const
Has file.
 
const fd_set * operator&() const
Address of operator.
 
bool empty() const
Check setting of file descriptors.
 
bool in_avail(JTimeval timeout=JTimeval::min())
Check availability of input.
 
JFileDescriptorMask(const JAbstractFile &file)
Constructor.
 
void reset(const int file_descriptor)
Reset file descriptor.
 
bool has(const int file_descriptor) const
Has file descriptor.
 
int getNumberOfFileDescriptors() const
Get number of file descriptors.
 
void set(const JAbstractFile &file)
Set file.
 
int number_of_file_descriptors
 
Auxiliary class for time values.
 
static JTimeval min()
Get minimal time value.
 
bool select(const Trk &trk, const Evt &evt)
Event selection.
 
Auxiliary classes and methods for language specific functionality.
 
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).