pva2pva 1.4.2
Loading...
Searching...
No Matches
DBCH Struct Reference

Public Member Functions

 DBCH (dbChannel *ch)
 DBCH (const std::string &name)
void swap (DBCH &)
 operator dbChannel * ()
 operator const dbChannel * () const
dbChannel * operator-> ()
const dbChannel * operator-> () const

Public Attributes

dbChannel * chan

Detailed Description

Definition at line 81 of file pvif.h.

Constructor & Destructor Documentation

◆ DBCH() [1/3]

DBCH::DBCH ( )
inline

Definition at line 83 of file pvif.h.

83:chan(0) {}

◆ DBCH() [2/3]

DBCH::DBCH ( dbChannel * ch)
explicit

Definition at line 41 of file pvif.cpp.

41 :chan(ch)
42{
43 if(!chan)
44 throw std::invalid_argument("NULL channel");
45 prepare();
46}

◆ DBCH() [3/3]

DBCH::DBCH ( const std::string & name)
explicit

Definition at line 48 of file pvif.cpp.

49 :chan(dbChannelCreate(name.c_str()))
50{
51 if(!chan)
52 throw std::invalid_argument(SB()<<"invalid channel: "<<name);
53 prepare();
54}

◆ ~DBCH()

DBCH::~DBCH ( )

Definition at line 66 of file pvif.cpp.

67{
68 if(chan) dbChannelDelete(chan);
69}

Member Function Documentation

◆ operator const dbChannel *()

DBCH::operator const dbChannel * ( ) const
inline

Definition at line 91 of file pvif.h.

91{ return chan; }

◆ operator dbChannel *()

DBCH::operator dbChannel * ( )
inline

Definition at line 90 of file pvif.h.

90{ return chan; }

◆ operator->() [1/2]

dbChannel * DBCH::operator-> ( )
inline

Definition at line 92 of file pvif.h.

92{ return chan; }

◆ operator->() [2/2]

const dbChannel * DBCH::operator-> ( ) const
inline

Definition at line 93 of file pvif.h.

93{ return chan; }

◆ swap()

void DBCH::swap ( DBCH & o)

Definition at line 71 of file pvif.cpp.

72{
73 std::swap(chan, o.chan);
74}

Member Data Documentation

◆ chan

dbChannel* DBCH::chan

Definition at line 82 of file pvif.h.


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