| The Gaudi Framework v32r1 (f65d50dc)

Public Member Functions | Private Attributes | List of all members
Io::IoFlags Class Referencefinal

`#include <GaudiKernel/IFileMgr.h>`

## Public Member Functions
| IoFlags ()=default
| IoFlags (int i)
int | f () const
bool | operator== (const IoFlags &fa) const
bool | operator== (const int &fa) const
IoFlags | operator| (const IoFlags &fa) const
IoFlags | operator| (const int &fa) const
| operator int () const
bool | isRead () const
bool | isWrite () const
bool | isRdWr () const
bool | isInvalid () const
bool | match (const IoFlags &fa, bool strict=true) const
std::string | bits () const

## Private Attributes
int | _f = INVALID

## Detailed Description

Definition at line 40 of file IFileMgr.h.

## Constructor & Destructor Documentation

## ◆ IoFlags() [1/2]

Io::IoFlags::IoFlags | ( |  | ) |
| default

## ◆ IoFlags() [2/2]

Io::IoFlags::IoFlags | ( | int | i | ) |
| inline

Definition at line 43 of file IFileMgr.h.

43 : _f( i ){};
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## Member Function Documentation

## ◆ bits()

std::string Io::IoFlags::bits | ( |  | ) | const
| inline

Definition at line 66 of file IFileMgr.h.

66 {
67 std::string s;
68 int f( _f );
69 const int SHIFT = 8 * sizeof( int ) - 1;
70 const unsigned MASK = 1 << SHIFT;
71
72 for ( int i = 1; i <= SHIFT + 1; ++i ) {
73 s += ( f & MASK ? '1' : '0' );
74 f <<= 1;
75 if ( i % 8 == 0 ) s += ' ';
76 }
77 return s;
78 }
Io::IoFlags::f
int f() const
Definition: IFileMgr.h:45
std::string
STL class.
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81
gaudirun.s
string s
Definition: gaudirun.py:316

## ◆ f()

int Io::IoFlags::f | ( |  | ) | const
| inline

Definition at line 45 of file IFileMgr.h.

45 { return _f; }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ isInvalid()

bool Io::IoFlags::isInvalid | ( |  | ) | const
| inline

Definition at line 58 of file IFileMgr.h.

58 { return ( ( _f & INVALID ) != 0 ); }
Io::INVALID
Definition: IFileMgr.h:37
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ isRdWr()

bool Io::IoFlags::isRdWr | ( |  | ) | const
| inline

Definition at line 57 of file IFileMgr.h.

57 { return ( ( _f & RDWR ) != 0 ); }
Io::RDWR
Definition: IFileMgr.h:29
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ isRead()

bool Io::IoFlags::isRead | ( |  | ) | const
| inline

Definition at line 55 of file IFileMgr.h.

55 { return ( _f == READ ); }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81
Io::READ
Definition: IFileMgr.h:27

## ◆ isWrite()

bool Io::IoFlags::isWrite | ( |  | ) | const
| inline

Definition at line 56 of file IFileMgr.h.

56 { return ( ( _f & WRITE ) != 0 ); }
Io::WRITE
Definition: IFileMgr.h:28
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ match()

bool Io::IoFlags::match | ( | const IoFlags & | fa,
|  | bool | strict = `true`
| ) |  | const
| inline

Definition at line 60 of file IFileMgr.h.

60 {
61 if ( strict ) { return ( _f == fa ); }
62 // only look at first 2 bits
63 return ( ( _f & 3 ) == ( fa & 3 ) );
64 }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ operator int()

Io::IoFlags::operator int | ( |  | ) | const
| inline

Definition at line 53 of file IFileMgr.h.

53 { return _f; }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ operator==() [1/2]

bool Io::IoFlags::operator== | ( | const IoFlags & | fa | ) | const
| inline

Definition at line 47 of file IFileMgr.h.

47 { return ( _f == fa.f() ); }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ operator==() [2/2]

bool Io::IoFlags::operator== | ( | const int & | fa | ) | const
| inline

Definition at line 48 of file IFileMgr.h.

48 { return ( _f == fa ); }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ operator|() [1/2]

IoFlags Io::IoFlags::operator| | ( | const IoFlags & | fa | ) | const
| inline

Definition at line 50 of file IFileMgr.h.

50 { return ( _f | fa.f() ); }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## ◆ operator|() [2/2]

IoFlags Io::IoFlags::operator| | ( | const int & | fa | ) | const
| inline

Definition at line 51 of file IFileMgr.h.

51 { return ( _f | fa ); }
Io::IoFlags::_f
int _f
Definition: IFileMgr.h:81

## Member Data Documentation

## ◆ _f

int Io::IoFlags::_f = INVALID
| private

Definition at line 81 of file IFileMgr.h.

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

- GaudiKernel/GaudiKernel/IFileMgr.h