use epics_throws macro
This commit is contained in:
@@ -33,7 +33,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
#ifdef autoPtrFreeListh_epicsExportSharedSymbols
|
#ifdef autoPtrFreeListh_epicsExportSharedSymbols
|
||||||
# define epicsExportSharedSymbols
|
# define epicsExportSharedSymbols
|
||||||
|
|||||||
+2
-2
@@ -45,7 +45,7 @@
|
|||||||
* between the 1st and 2nd beacons)
|
* between the 1st and 2nd beacons)
|
||||||
*/
|
*/
|
||||||
bhe::bhe ( const epicsTime & initialTimeStamp,
|
bhe::bhe ( const epicsTime & initialTimeStamp,
|
||||||
unsigned initialBeaconNumber, const inetAddrID & addr ) throw () :
|
unsigned initialBeaconNumber, const inetAddrID & addr ) epics_throws (()) :
|
||||||
inetAddrID ( addr ), timeStamp ( initialTimeStamp ), averagePeriod ( - DBL_MAX ),
|
inetAddrID ( addr ), timeStamp ( initialTimeStamp ), averagePeriod ( - DBL_MAX ),
|
||||||
lastBeaconNumber ( initialBeaconNumber )
|
lastBeaconNumber ( initialBeaconNumber )
|
||||||
{
|
{
|
||||||
@@ -224,7 +224,7 @@ void bhe::show ( unsigned /* level */ ) const
|
|||||||
static_cast <const void *> ( this ), this->averagePeriod );
|
static_cast <const void *> ( this ), this->averagePeriod );
|
||||||
}
|
}
|
||||||
|
|
||||||
double bhe::period () const throw ()
|
double bhe::period () const epics_throws (())
|
||||||
{
|
{
|
||||||
return this->averagePeriod;
|
return this->averagePeriod;
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-3
@@ -31,7 +31,7 @@
|
|||||||
#include "tsDLList.h"
|
#include "tsDLList.h"
|
||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "epicsTime.h"
|
#include "epicsTime.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
#ifdef bhehEpicsExportSharedSymbols
|
#ifdef bhehEpicsExportSharedSymbols
|
||||||
# define epicsExportSharedSymbols
|
# define epicsExportSharedSymbols
|
||||||
@@ -56,13 +56,13 @@ public:
|
|||||||
class bhe : public tsSLNode < bhe >, public inetAddrID {
|
class bhe : public tsSLNode < bhe >, public inetAddrID {
|
||||||
public:
|
public:
|
||||||
epicsShareFunc bhe ( const epicsTime & initialTimeStamp,
|
epicsShareFunc bhe ( const epicsTime & initialTimeStamp,
|
||||||
unsigned initialBeaconNumber, const inetAddrID & addr ) throw ();
|
unsigned initialBeaconNumber, const inetAddrID & addr ) epics_throws (());
|
||||||
epicsShareFunc ~bhe ();
|
epicsShareFunc ~bhe ();
|
||||||
epicsShareFunc bool updatePeriod (
|
epicsShareFunc bool updatePeriod (
|
||||||
const epicsTime & programBeginTime,
|
const epicsTime & programBeginTime,
|
||||||
const epicsTime & currentTime, ca_uint32_t beaconNumber,
|
const epicsTime & currentTime, ca_uint32_t beaconNumber,
|
||||||
unsigned protocolRevision );
|
unsigned protocolRevision );
|
||||||
epicsShareFunc double period () const throw ();
|
epicsShareFunc double period () const epics_throws (());
|
||||||
epicsShareFunc epicsTime updateTime () const;
|
epicsShareFunc epicsTime updateTime () const;
|
||||||
epicsShareFunc void show ( unsigned level) const;
|
epicsShareFunc void show ( unsigned level) const;
|
||||||
epicsShareFunc void registerIIU ( tcpiiu & );
|
epicsShareFunc void registerIIU ( tcpiiu & );
|
||||||
|
|||||||
+2
-2
@@ -1587,12 +1587,12 @@ void cac::initiateConnect ( nciu & chan )
|
|||||||
this->pudpiiu->installChannel ( chan );
|
this->pudpiiu->installChannel ( chan );
|
||||||
}
|
}
|
||||||
|
|
||||||
void *cacComBufMemoryManager::allocate ( size_t size ) throw ( std::bad_alloc )
|
void *cacComBufMemoryManager::allocate ( size_t size ) epics_throws (( std::bad_alloc ))
|
||||||
{
|
{
|
||||||
return this->freeList.allocate ( size );
|
return this->freeList.allocate ( size );
|
||||||
}
|
}
|
||||||
|
|
||||||
void cacComBufMemoryManager::release ( void * pCadaver ) throw ()
|
void cacComBufMemoryManager::release ( void * pCadaver ) epics_throws (())
|
||||||
{
|
{
|
||||||
return this->freeList.release ( pCadaver );
|
return this->freeList.release ( pCadaver );
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-2
@@ -31,6 +31,7 @@
|
|||||||
# undef epicsExportSharedSymbols
|
# undef epicsExportSharedSymbols
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include "cxxCompilerDependencies.h"
|
||||||
#include "ipAddrToAsciiAsynchronous.h"
|
#include "ipAddrToAsciiAsynchronous.h"
|
||||||
#include "epicsTimer.h"
|
#include "epicsTimer.h"
|
||||||
#include "epicsEvent.h"
|
#include "epicsEvent.h"
|
||||||
@@ -98,8 +99,8 @@ private:
|
|||||||
class cacComBufMemoryManager : public comBufMemoryManager
|
class cacComBufMemoryManager : public comBufMemoryManager
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
void * allocate ( size_t ) throw ( std::bad_alloc );
|
void * allocate ( size_t ) epics_throws (( std::bad_alloc ));
|
||||||
void release ( void * ) throw ();
|
void release ( void * ) epics_throws (());
|
||||||
private:
|
private:
|
||||||
tsFreeList < class comBuf, 0x20 > freeList;
|
tsFreeList < class comBuf, 0x20 > freeList;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -88,17 +88,16 @@ const char * cacChannel::pHostName () const
|
|||||||
return ref->pointer ();
|
return ref->pointer ();
|
||||||
}
|
}
|
||||||
|
|
||||||
// ms visual c++ 7.0 appears to require these when they
|
|
||||||
// are not called?
|
|
||||||
void cacChannel::operator delete ( void * )
|
void cacChannel::operator delete ( void * )
|
||||||
{
|
{
|
||||||
throw std::logic_error (
|
// Visual C++ .net appears to require operator delete if
|
||||||
"why is the compiler calling cacChannel::operator delete?" );
|
// placement operator delete is defined? I smell a ms rat
|
||||||
}
|
// because if I declare placement new and delete, but
|
||||||
void cacChannel::operator delete [] ( void * )
|
// comment out the placement delete definition there are
|
||||||
{
|
// no undefined symbols.
|
||||||
throw std::logic_error (
|
errlogPrintf ( "%s:%d this compiler is confused about placement delete - memory was probably leaked",
|
||||||
"why is the compiler calling cacChannel::operator delete?" );
|
__FILE__, __LINE__ );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -205,9 +205,7 @@ private:
|
|||||||
cacChannel ( const cacChannel & );
|
cacChannel ( const cacChannel & );
|
||||||
cacChannel & operator = ( const cacChannel & );
|
cacChannel & operator = ( const cacChannel & );
|
||||||
void * operator new ( size_t );
|
void * operator new ( size_t );
|
||||||
void * operator new [] ( size_t );
|
|
||||||
void operator delete ( void * );
|
void operator delete ( void * );
|
||||||
void operator delete [] ( void * );
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class cacNotify { // X aCC 655
|
class cacNotify { // X aCC 655
|
||||||
|
|||||||
+8
-9
@@ -32,7 +32,7 @@
|
|||||||
#include "comBuf.h"
|
#include "comBuf.h"
|
||||||
#include "errlog.h"
|
#include "errlog.h"
|
||||||
|
|
||||||
bool comBuf::flushToWire ( wireSendAdapter & wire ) throw ()
|
bool comBuf::flushToWire ( wireSendAdapter & wire ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned occupied = this->occupiedBytes ();
|
unsigned occupied = this->occupiedBytes ();
|
||||||
while ( occupied ) {
|
while ( occupied ) {
|
||||||
@@ -47,7 +47,7 @@ bool comBuf::flushToWire ( wireSendAdapter & wire ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comBuf::push ( const epicsInt16 * pValue, unsigned nElem ) throw ()
|
unsigned comBuf::push ( const epicsInt16 * pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
||||||
for ( unsigned i = 0u; i < nElem; i++ ) {
|
for ( unsigned i = 0u; i < nElem; i++ ) {
|
||||||
@@ -59,7 +59,7 @@ unsigned comBuf::push ( const epicsInt16 * pValue, unsigned nElem ) throw ()
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comBuf::push ( const epicsUInt16 * pValue, unsigned nElem ) throw ()
|
unsigned comBuf::push ( const epicsUInt16 * pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
||||||
for ( unsigned i = 0u; i < nElem; i++ ) {
|
for ( unsigned i = 0u; i < nElem; i++ ) {
|
||||||
@@ -71,7 +71,7 @@ unsigned comBuf::push ( const epicsUInt16 * pValue, unsigned nElem ) throw ()
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comBuf::push ( const epicsInt32 * pValue, unsigned nElem ) throw ()
|
unsigned comBuf::push ( const epicsInt32 * pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
||||||
for ( unsigned i = 0u; i < nElem; i++ ) {
|
for ( unsigned i = 0u; i < nElem; i++ ) {
|
||||||
@@ -87,7 +87,7 @@ unsigned comBuf::push ( const epicsInt32 * pValue, unsigned nElem ) throw ()
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comBuf::push ( const epicsUInt32 * pValue, unsigned nElem ) throw ()
|
unsigned comBuf::push ( const epicsUInt32 * pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
||||||
for ( unsigned i = 0u; i < nElem; i++ ) {
|
for ( unsigned i = 0u; i < nElem; i++ ) {
|
||||||
@@ -103,7 +103,7 @@ unsigned comBuf::push ( const epicsUInt32 * pValue, unsigned nElem ) throw ()
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comBuf::push ( const epicsFloat32 * pValue, unsigned nElem ) throw ()
|
unsigned comBuf::push ( const epicsFloat32 * pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
||||||
for ( unsigned i = 0u; i < nElem; i++ ) {
|
for ( unsigned i = 0u; i < nElem; i++ ) {
|
||||||
@@ -114,7 +114,7 @@ unsigned comBuf::push ( const epicsFloat32 * pValue, unsigned nElem ) throw ()
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comBuf::push ( const epicsFloat64 * pValue, unsigned nElem ) throw ()
|
unsigned comBuf::push ( const epicsFloat64 * pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
||||||
for ( unsigned i = 0u; i < nElem; i++ ) {
|
for ( unsigned i = 0u; i < nElem; i++ ) {
|
||||||
@@ -128,13 +128,12 @@ unsigned comBuf::push ( const epicsFloat64 * pValue, unsigned nElem ) throw ()
|
|||||||
// throwing the exception from a function that isnt inline
|
// throwing the exception from a function that isnt inline
|
||||||
// shrinks the GNU compiled object code
|
// shrinks the GNU compiled object code
|
||||||
void comBuf::throwInsufficentBytesException ()
|
void comBuf::throwInsufficentBytesException ()
|
||||||
throw ( insufficentBytesAvailable )
|
epics_throws (( insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
throw insufficentBytesAvailable ();
|
throw insufficentBytesAvailable ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void comBuf::operator delete ( void *pCadaver )
|
void comBuf::operator delete ( void *pCadaver )
|
||||||
throw ( std::logic_error )
|
|
||||||
{
|
{
|
||||||
// Visual C++ .net appears to require operator delete if
|
// Visual C++ .net appears to require operator delete if
|
||||||
// placement operator delete is defined? I smell a ms rat
|
// placement operator delete is defined? I smell a ms rat
|
||||||
|
|||||||
+83
-85
@@ -34,7 +34,7 @@
|
|||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "tsDLList.h"
|
#include "tsDLList.h"
|
||||||
#include "osiWireFormat.h"
|
#include "osiWireFormat.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
static const unsigned comBufSize = 0x4000;
|
static const unsigned comBufSize = 0x4000;
|
||||||
|
|
||||||
@@ -43,130 +43,128 @@ class comBufMemoryManager {
|
|||||||
public:
|
public:
|
||||||
virtual ~comBufMemoryManager ();
|
virtual ~comBufMemoryManager ();
|
||||||
virtual void * allocate ( size_t )
|
virtual void * allocate ( size_t )
|
||||||
throw ( std::bad_alloc ) = 0;
|
epics_throws (( std::bad_alloc )) = 0;
|
||||||
virtual void release ( void * )
|
virtual void release ( void * )
|
||||||
throw () = 0;
|
epics_throws (()) = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
class wireSendAdapter { // X aCC 655
|
class wireSendAdapter { // X aCC 655
|
||||||
public:
|
public:
|
||||||
virtual unsigned sendBytes ( const void *pBuf,
|
virtual unsigned sendBytes ( const void *pBuf,
|
||||||
unsigned nBytesInBuf ) throw () = 0;
|
unsigned nBytesInBuf ) epics_throws (()) = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
class wireRecvAdapter { // X aCC 655
|
class wireRecvAdapter { // X aCC 655
|
||||||
public:
|
public:
|
||||||
virtual unsigned recvBytes ( void *pBuf,
|
virtual unsigned recvBytes ( void *pBuf,
|
||||||
unsigned nBytesInBuf ) throw () = 0;
|
unsigned nBytesInBuf ) epics_throws (()) = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
class comBuf : public tsDLNode < comBuf > {
|
class comBuf : public tsDLNode < comBuf > {
|
||||||
public:
|
public:
|
||||||
class insufficentBytesAvailable {};
|
class insufficentBytesAvailable {};
|
||||||
comBuf () throw();
|
comBuf () epics_throws (());
|
||||||
unsigned unoccupiedBytes () const throw();
|
unsigned unoccupiedBytes () const epics_throws (());
|
||||||
unsigned occupiedBytes () const throw();
|
unsigned occupiedBytes () const epics_throws (());
|
||||||
unsigned uncommittedBytes () const throw();
|
unsigned uncommittedBytes () const epics_throws (());
|
||||||
static unsigned capacityBytes () throw();
|
static unsigned capacityBytes () epics_throws (());
|
||||||
void clear () throw ();
|
void clear () epics_throws (());
|
||||||
unsigned copyInBytes ( const void *pBuf, unsigned nBytes ) throw();
|
unsigned copyInBytes ( const void *pBuf, unsigned nBytes ) epics_throws (());
|
||||||
unsigned push ( comBuf & ) throw();
|
unsigned push ( comBuf & ) epics_throws (());
|
||||||
bool push ( const epicsInt8 & value ) throw();
|
bool push ( const epicsInt8 & value ) epics_throws (());
|
||||||
bool push ( const epicsUInt8 & value ) throw();
|
bool push ( const epicsUInt8 & value ) epics_throws (());
|
||||||
bool push ( const epicsInt16 & value ) throw();
|
bool push ( const epicsInt16 & value ) epics_throws (());
|
||||||
bool push ( const epicsUInt16 & value ) throw();
|
bool push ( const epicsUInt16 & value ) epics_throws (());
|
||||||
bool push ( const epicsInt32 & value ) throw();
|
bool push ( const epicsInt32 & value ) epics_throws (());
|
||||||
bool push ( const epicsUInt32 & value ) throw();
|
bool push ( const epicsUInt32 & value ) epics_throws (());
|
||||||
bool push ( const epicsFloat32 & value ) throw();
|
bool push ( const epicsFloat32 & value ) epics_throws (());
|
||||||
bool push ( const epicsFloat64 & value ) throw();
|
bool push ( const epicsFloat64 & value ) epics_throws (());
|
||||||
bool push ( const epicsOldString & value ) throw();
|
bool push ( const epicsOldString & value ) epics_throws (());
|
||||||
unsigned push ( const epicsInt8 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsInt8 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsUInt8 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsUInt8 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsInt16 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsInt16 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsUInt16 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsUInt16 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsInt32 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsInt32 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsUInt32 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsUInt32 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsFloat32 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsFloat32 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsFloat64 *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsFloat64 *pValue, unsigned nElem ) epics_throws (());
|
||||||
unsigned push ( const epicsOldString *pValue, unsigned nElem ) throw();
|
unsigned push ( const epicsOldString *pValue, unsigned nElem ) epics_throws (());
|
||||||
void commitIncomming () throw();
|
void commitIncomming () epics_throws (());
|
||||||
void clearUncommittedIncomming () throw();
|
void clearUncommittedIncomming () epics_throws (());
|
||||||
bool copyInAllBytes ( const void *pBuf, unsigned nBytes ) throw();
|
bool copyInAllBytes ( const void *pBuf, unsigned nBytes ) epics_throws (());
|
||||||
unsigned copyOutBytes ( void *pBuf, unsigned nBytes ) throw();
|
unsigned copyOutBytes ( void *pBuf, unsigned nBytes ) epics_throws (());
|
||||||
bool copyOutAllBytes ( void *pBuf, unsigned nBytes ) throw();
|
bool copyOutAllBytes ( void *pBuf, unsigned nBytes ) epics_throws (());
|
||||||
unsigned removeBytes ( unsigned nBytes ) throw();
|
unsigned removeBytes ( unsigned nBytes ) epics_throws (());
|
||||||
bool flushToWire ( wireSendAdapter & ) throw ();
|
bool flushToWire ( wireSendAdapter & ) epics_throws (());
|
||||||
unsigned fillFromWire ( wireRecvAdapter & ) throw ();
|
unsigned fillFromWire ( wireRecvAdapter & ) epics_throws (());
|
||||||
epicsUInt8 popUInt8 ()
|
epicsUInt8 popUInt8 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable );
|
epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsUInt16 popUInt16 ()
|
epicsUInt16 popUInt16 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable );
|
epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsUInt32 popUInt32 ()
|
epicsUInt32 popUInt32 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable );
|
epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
static void throwInsufficentBytesException ()
|
static void throwInsufficentBytesException ()
|
||||||
throw ( comBuf::insufficentBytesAvailable );
|
epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
void * operator new ( size_t size,
|
void * operator new ( size_t size,
|
||||||
comBufMemoryManager & ) throw ( std::bad_alloc );
|
comBufMemoryManager & ) epics_throws (( std::bad_alloc ));
|
||||||
# ifdef CXX_PLACEMENT_DELETE
|
# ifdef CXX_PLACEMENT_DELETE
|
||||||
void operator delete ( void *,
|
void operator delete ( void *,
|
||||||
comBufMemoryManager & ) throw ();
|
comBufMemoryManager & ) epics_throws (());
|
||||||
# endif
|
# endif
|
||||||
private:
|
private:
|
||||||
unsigned commitIndex;
|
unsigned commitIndex;
|
||||||
unsigned nextWriteIndex;
|
unsigned nextWriteIndex;
|
||||||
unsigned nextReadIndex;
|
unsigned nextReadIndex;
|
||||||
epicsUInt8 buf [ comBufSize ];
|
epicsUInt8 buf [ comBufSize ];
|
||||||
unsigned unoccupiedElem ( unsigned elemSize, unsigned nElem ) throw ();
|
unsigned unoccupiedElem ( unsigned elemSize, unsigned nElem ) epics_throws (());
|
||||||
unsigned occupiedElem ( unsigned elemSize, unsigned nElem ) throw ();
|
unsigned occupiedElem ( unsigned elemSize, unsigned nElem ) epics_throws (());
|
||||||
void * operator new ( size_t size ) throw ( std::bad_alloc );
|
void * operator new ( size_t size ) epics_throws (( std::bad_alloc ));
|
||||||
void operator delete ( void * ) throw ( std::logic_error );
|
void operator delete ( void * ) epics_throws (());
|
||||||
void * operator new [] ( size_t size ) throw ( std::bad_alloc );
|
|
||||||
void operator delete [] ( void * ) throw ( std::logic_error );
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline void * comBuf::operator new ( size_t size,
|
inline void * comBuf::operator new ( size_t size,
|
||||||
comBufMemoryManager & mgr )
|
comBufMemoryManager & mgr )
|
||||||
throw ( std::bad_alloc )
|
epics_throws (( std::bad_alloc ))
|
||||||
{
|
{
|
||||||
return mgr.allocate ( size );
|
return mgr.allocate ( size );
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CXX_PLACEMENT_DELETE
|
#ifdef CXX_PLACEMENT_DELETE
|
||||||
inline void comBuf::operator delete ( void * pCadaver,
|
inline void comBuf::operator delete ( void * pCadaver,
|
||||||
comBufMemoryManager & mgr ) throw ()
|
comBufMemoryManager & mgr ) epics_throws (())
|
||||||
{
|
{
|
||||||
mgr.release ( pCadaver );
|
mgr.release ( pCadaver );
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
inline comBuf::comBuf () throw () : commitIndex ( 0u ),
|
inline comBuf::comBuf () epics_throws (()) : commitIndex ( 0u ),
|
||||||
nextWriteIndex ( 0u ), nextReadIndex ( 0u )
|
nextWriteIndex ( 0u ), nextReadIndex ( 0u )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comBuf::clear () throw ()
|
inline void comBuf::clear () epics_throws (())
|
||||||
{
|
{
|
||||||
this->commitIndex = 0u;
|
this->commitIndex = 0u;
|
||||||
this->nextWriteIndex = 0u;
|
this->nextWriteIndex = 0u;
|
||||||
this->nextReadIndex = 0u;
|
this->nextReadIndex = 0u;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::unoccupiedBytes () const throw ()
|
inline unsigned comBuf::unoccupiedBytes () const epics_throws (())
|
||||||
{
|
{
|
||||||
return sizeof ( this->buf ) - this->nextWriteIndex;
|
return sizeof ( this->buf ) - this->nextWriteIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::occupiedBytes () const throw ()
|
inline unsigned comBuf::occupiedBytes () const epics_throws (())
|
||||||
{
|
{
|
||||||
return this->commitIndex - this->nextReadIndex;
|
return this->commitIndex - this->nextReadIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::uncommittedBytes () const throw ()
|
inline unsigned comBuf::uncommittedBytes () const epics_throws (())
|
||||||
{
|
{
|
||||||
return this->nextWriteIndex - this->commitIndex;
|
return this->nextWriteIndex - this->commitIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::push ( comBuf & bufIn ) throw ()
|
inline unsigned comBuf::push ( comBuf & bufIn ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned nBytes = this->copyInBytes (
|
unsigned nBytes = this->copyInBytes (
|
||||||
& bufIn.buf[ bufIn.nextReadIndex ],
|
& bufIn.buf[ bufIn.nextReadIndex ],
|
||||||
@@ -175,12 +173,12 @@ inline unsigned comBuf::push ( comBuf & bufIn ) throw ()
|
|||||||
return nBytes;
|
return nBytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::capacityBytes () throw ()
|
inline unsigned comBuf::capacityBytes () epics_throws (())
|
||||||
{
|
{
|
||||||
return comBufSize;
|
return comBufSize;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::fillFromWire ( wireRecvAdapter & wire ) throw ()
|
inline unsigned comBuf::fillFromWire ( wireRecvAdapter & wire ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned nNewBytes = wire.recvBytes (
|
unsigned nNewBytes = wire.recvBytes (
|
||||||
& this->buf[this->nextWriteIndex],
|
& this->buf[this->nextWriteIndex],
|
||||||
@@ -189,7 +187,7 @@ inline unsigned comBuf::fillFromWire ( wireRecvAdapter & wire ) throw ()
|
|||||||
return nNewBytes;
|
return nNewBytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::unoccupiedElem ( unsigned elemSize, unsigned nElem ) throw ()
|
inline unsigned comBuf::unoccupiedElem ( unsigned elemSize, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned avail = this->unoccupiedBytes ();
|
unsigned avail = this->unoccupiedBytes ();
|
||||||
if ( elemSize * nElem > avail ) {
|
if ( elemSize * nElem > avail ) {
|
||||||
@@ -198,7 +196,7 @@ inline unsigned comBuf::unoccupiedElem ( unsigned elemSize, unsigned nElem ) thr
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsInt8 & value ) throw ()
|
inline bool comBuf::push ( const epicsInt8 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -208,7 +206,7 @@ inline bool comBuf::push ( const epicsInt8 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsUInt8 & value ) throw ()
|
inline bool comBuf::push ( const epicsUInt8 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -217,7 +215,7 @@ inline bool comBuf::push ( const epicsUInt8 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsInt16 & value ) throw ()
|
inline bool comBuf::push ( const epicsInt16 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -229,7 +227,7 @@ inline bool comBuf::push ( const epicsInt16 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsUInt16 & value ) throw ()
|
inline bool comBuf::push ( const epicsUInt16 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -241,7 +239,7 @@ inline bool comBuf::push ( const epicsUInt16 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsInt32 & value ) throw ()
|
inline bool comBuf::push ( const epicsInt32 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -257,7 +255,7 @@ inline bool comBuf::push ( const epicsInt32 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsUInt32 & value ) throw ()
|
inline bool comBuf::push ( const epicsUInt32 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -273,7 +271,7 @@ inline bool comBuf::push ( const epicsUInt32 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsFloat32 & value ) throw ()
|
inline bool comBuf::push ( const epicsFloat32 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -284,7 +282,7 @@ inline bool comBuf::push ( const epicsFloat32 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsFloat64 & value ) throw ()
|
inline bool comBuf::push ( const epicsFloat64 & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -295,7 +293,7 @@ inline bool comBuf::push ( const epicsFloat64 & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::push ( const epicsOldString & value ) throw ()
|
inline bool comBuf::push ( const epicsOldString & value ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
if ( this->unoccupiedBytes () < sizeof ( value ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -305,17 +303,17 @@ inline bool comBuf::push ( const epicsOldString & value ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::push ( const epicsInt8 *pValue, unsigned nElem ) throw ()
|
inline unsigned comBuf::push ( const epicsInt8 *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
return copyInBytes ( pValue, nElem );
|
return copyInBytes ( pValue, nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::push ( const epicsUInt8 *pValue, unsigned nElem ) throw ()
|
inline unsigned comBuf::push ( const epicsUInt8 *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
return copyInBytes ( pValue, nElem );
|
return copyInBytes ( pValue, nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::push ( const epicsOldString *pValue, unsigned nElem ) throw ()
|
inline unsigned comBuf::push ( const epicsOldString *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
nElem = this->unoccupiedElem ( sizeof (*pValue), nElem );
|
||||||
unsigned size = nElem * sizeof ( *pValue );
|
unsigned size = nElem * sizeof ( *pValue );
|
||||||
@@ -324,7 +322,7 @@ inline unsigned comBuf::push ( const epicsOldString *pValue, unsigned nElem ) th
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::occupiedElem ( unsigned elemSize, unsigned nElem ) throw ()
|
inline unsigned comBuf::occupiedElem ( unsigned elemSize, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned avail = this->occupiedBytes ();
|
unsigned avail = this->occupiedBytes ();
|
||||||
if ( elemSize * nElem > avail ) {
|
if ( elemSize * nElem > avail ) {
|
||||||
@@ -333,17 +331,17 @@ inline unsigned comBuf::occupiedElem ( unsigned elemSize, unsigned nElem ) throw
|
|||||||
return nElem;
|
return nElem;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comBuf::commitIncomming () throw ()
|
inline void comBuf::commitIncomming () epics_throws (())
|
||||||
{
|
{
|
||||||
this->commitIndex = this->nextWriteIndex;
|
this->commitIndex = this->nextWriteIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comBuf::clearUncommittedIncomming () throw ()
|
inline void comBuf::clearUncommittedIncomming () epics_throws (())
|
||||||
{
|
{
|
||||||
this->nextWriteIndex = this->commitIndex;
|
this->nextWriteIndex = this->commitIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::copyInAllBytes ( const void *pBuf, unsigned nBytes ) throw ()
|
inline bool comBuf::copyInAllBytes ( const void *pBuf, unsigned nBytes ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( nBytes <= this->unoccupiedBytes () ) {
|
if ( nBytes <= this->unoccupiedBytes () ) {
|
||||||
memcpy ( & this->buf[this->nextWriteIndex], pBuf, nBytes );
|
memcpy ( & this->buf[this->nextWriteIndex], pBuf, nBytes );
|
||||||
@@ -353,7 +351,7 @@ inline bool comBuf::copyInAllBytes ( const void *pBuf, unsigned nBytes ) throw (
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::copyInBytes ( const void *pBuf, unsigned nBytes ) throw ()
|
inline unsigned comBuf::copyInBytes ( const void *pBuf, unsigned nBytes ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( nBytes > 0u ) {
|
if ( nBytes > 0u ) {
|
||||||
unsigned available = this->unoccupiedBytes ();
|
unsigned available = this->unoccupiedBytes ();
|
||||||
@@ -366,7 +364,7 @@ inline unsigned comBuf::copyInBytes ( const void *pBuf, unsigned nBytes ) throw
|
|||||||
return nBytes;
|
return nBytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comBuf::copyOutAllBytes ( void * pBuf, unsigned nBytes ) throw ()
|
inline bool comBuf::copyOutAllBytes ( void * pBuf, unsigned nBytes ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( nBytes <= this->occupiedBytes () ) {
|
if ( nBytes <= this->occupiedBytes () ) {
|
||||||
memcpy ( pBuf, &this->buf[this->nextReadIndex], nBytes);
|
memcpy ( pBuf, &this->buf[this->nextReadIndex], nBytes);
|
||||||
@@ -376,7 +374,7 @@ inline bool comBuf::copyOutAllBytes ( void * pBuf, unsigned nBytes ) throw ()
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::copyOutBytes ( void *pBuf, unsigned nBytes ) throw ()
|
inline unsigned comBuf::copyOutBytes ( void *pBuf, unsigned nBytes ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned occupied = this->occupiedBytes ();
|
unsigned occupied = this->occupiedBytes ();
|
||||||
if ( nBytes > occupied ) {
|
if ( nBytes > occupied ) {
|
||||||
@@ -387,7 +385,7 @@ inline unsigned comBuf::copyOutBytes ( void *pBuf, unsigned nBytes ) throw ()
|
|||||||
return nBytes;
|
return nBytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comBuf::removeBytes ( unsigned nBytes ) throw ()
|
inline unsigned comBuf::removeBytes ( unsigned nBytes ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned occupied = this->occupiedBytes ();
|
unsigned occupied = this->occupiedBytes ();
|
||||||
if ( nBytes > occupied ) {
|
if ( nBytes > occupied ) {
|
||||||
@@ -398,7 +396,7 @@ inline unsigned comBuf::removeBytes ( unsigned nBytes ) throw ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline epicsUInt8 comBuf::popUInt8 ()
|
inline epicsUInt8 comBuf::popUInt8 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
if ( this->occupiedBytes () < 1u ) {
|
if ( this->occupiedBytes () < 1u ) {
|
||||||
comBuf::throwInsufficentBytesException ();
|
comBuf::throwInsufficentBytesException ();
|
||||||
@@ -407,7 +405,7 @@ inline epicsUInt8 comBuf::popUInt8 ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline epicsUInt16 comBuf::popUInt16 ()
|
inline epicsUInt16 comBuf::popUInt16 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
if ( this->occupiedBytes () < 2u ) {
|
if ( this->occupiedBytes () < 2u ) {
|
||||||
comBuf::throwInsufficentBytesException ();
|
comBuf::throwInsufficentBytesException ();
|
||||||
@@ -418,7 +416,7 @@ inline epicsUInt16 comBuf::popUInt16 ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline epicsUInt32 comBuf::popUInt32 ()
|
inline epicsUInt32 comBuf::popUInt32 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
if ( this->occupiedBytes () < 4u ) {
|
if ( this->occupiedBytes () < 4u ) {
|
||||||
comBuf::throwInsufficentBytesException ();
|
comBuf::throwInsufficentBytesException ();
|
||||||
|
|||||||
+10
-10
@@ -27,17 +27,17 @@
|
|||||||
#include "iocinf.h"
|
#include "iocinf.h"
|
||||||
#include "virtualCircuit.h"
|
#include "virtualCircuit.h"
|
||||||
|
|
||||||
comQueRecv::comQueRecv ( comBufMemoryManager & comBufMemoryManagerIn ) throw () :
|
comQueRecv::comQueRecv ( comBufMemoryManager & comBufMemoryManagerIn ) epics_throws (()) :
|
||||||
comBufMemMgr ( comBufMemoryManagerIn ), nBytesPending ( 0u )
|
comBufMemMgr ( comBufMemoryManagerIn ), nBytesPending ( 0u )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
comQueRecv::~comQueRecv () throw ()
|
comQueRecv::~comQueRecv () epics_throws (())
|
||||||
{
|
{
|
||||||
this->clear ();
|
this->clear ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueRecv::clear () throw ()
|
void comQueRecv::clear () epics_throws (())
|
||||||
{
|
{
|
||||||
comBuf *pBuf;
|
comBuf *pBuf;
|
||||||
while ( ( pBuf = this->bufs.get () ) ) {
|
while ( ( pBuf = this->bufs.get () ) ) {
|
||||||
@@ -47,7 +47,7 @@ void comQueRecv::clear () throw ()
|
|||||||
this->nBytesPending = 0u;
|
this->nBytesPending = 0u;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comQueRecv::copyOutBytes ( epicsInt8 *pBuf, unsigned nBytes ) throw ()
|
unsigned comQueRecv::copyOutBytes ( epicsInt8 *pBuf, unsigned nBytes ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned totalBytes = 0u;
|
unsigned totalBytes = 0u;
|
||||||
do {
|
do {
|
||||||
@@ -68,7 +68,7 @@ unsigned comQueRecv::copyOutBytes ( epicsInt8 *pBuf, unsigned nBytes ) throw ()
|
|||||||
return totalBytes;
|
return totalBytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned comQueRecv::removeBytes ( unsigned nBytes ) throw ()
|
unsigned comQueRecv::removeBytes ( unsigned nBytes ) epics_throws (())
|
||||||
{
|
{
|
||||||
unsigned totalBytes = 0u;
|
unsigned totalBytes = 0u;
|
||||||
unsigned bytesLeft = nBytes;
|
unsigned bytesLeft = nBytes;
|
||||||
@@ -95,7 +95,7 @@ unsigned comQueRecv::removeBytes ( unsigned nBytes ) throw ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
void comQueRecv::popString ( epicsOldString *pStr )
|
void comQueRecv::popString ( epicsOldString *pStr )
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
for ( unsigned i = 0u; i < sizeof ( *pStr ); i++ ) {
|
for ( unsigned i = 0u; i < sizeof ( *pStr ); i++ ) {
|
||||||
pStr[0][i] = this->popInt8 ();
|
pStr[0][i] = this->popInt8 ();
|
||||||
@@ -103,7 +103,7 @@ void comQueRecv::popString ( epicsOldString *pStr )
|
|||||||
}
|
}
|
||||||
|
|
||||||
void comQueRecv::pushLastComBufReceived ( comBuf & bufIn )
|
void comQueRecv::pushLastComBufReceived ( comBuf & bufIn )
|
||||||
throw ()
|
epics_throws (())
|
||||||
{
|
{
|
||||||
bufIn.commitIncomming ();
|
bufIn.commitIncomming ();
|
||||||
comBuf * pComBuf = this->bufs.last ();
|
comBuf * pComBuf = this->bufs.last ();
|
||||||
@@ -128,7 +128,7 @@ void comQueRecv::pushLastComBufReceived ( comBuf & bufIn )
|
|||||||
// 2) using canonical unsigned tmp avoids ANSI C conversions to int
|
// 2) using canonical unsigned tmp avoids ANSI C conversions to int
|
||||||
// 3) cast required because sizeof(unsigned) >= sizeof(epicsUInt32)
|
// 3) cast required because sizeof(unsigned) >= sizeof(epicsUInt32)
|
||||||
epicsUInt16 comQueRecv::multiBufferPopUInt16 ()
|
epicsUInt16 comQueRecv::multiBufferPopUInt16 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
epicsUInt16 tmp;
|
epicsUInt16 tmp;
|
||||||
if ( this->occupiedBytes() >= sizeof (tmp) ) {
|
if ( this->occupiedBytes() >= sizeof (tmp) ) {
|
||||||
@@ -147,7 +147,7 @@ epicsUInt16 comQueRecv::multiBufferPopUInt16 ()
|
|||||||
// 2) using canonical unsigned temporary avoids ANSI C conversions to int
|
// 2) using canonical unsigned temporary avoids ANSI C conversions to int
|
||||||
// 3) cast required because sizeof(unsigned) >= sizeof(epicsUInt32)
|
// 3) cast required because sizeof(unsigned) >= sizeof(epicsUInt32)
|
||||||
epicsUInt32 comQueRecv::multiBufferPopUInt32 ()
|
epicsUInt32 comQueRecv::multiBufferPopUInt32 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
epicsUInt32 tmp;
|
epicsUInt32 tmp;
|
||||||
if ( this->occupiedBytes() >= sizeof (tmp) ) {
|
if ( this->occupiedBytes() >= sizeof (tmp) ) {
|
||||||
@@ -168,7 +168,7 @@ epicsUInt32 comQueRecv::multiBufferPopUInt32 ()
|
|||||||
return tmp;
|
return tmp;
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueRecv::removeAndDestroyBuf ( comBuf & buf ) throw ()
|
void comQueRecv::removeAndDestroyBuf ( comBuf & buf ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->bufs.remove ( buf );
|
this->bufs.remove ( buf );
|
||||||
buf.~comBuf ();
|
buf.~comBuf ();
|
||||||
|
|||||||
+32
-30
@@ -27,56 +27,58 @@
|
|||||||
#ifndef comQueRecvh
|
#ifndef comQueRecvh
|
||||||
#define comQueRecvh
|
#define comQueRecvh
|
||||||
|
|
||||||
|
#include "comBuf.h"
|
||||||
|
|
||||||
class comQueRecv {
|
class comQueRecv {
|
||||||
public:
|
public:
|
||||||
comQueRecv ( comBufMemoryManager & ) throw ();
|
comQueRecv ( comBufMemoryManager & ) epics_throws (());
|
||||||
~comQueRecv () throw ();
|
~comQueRecv () epics_throws (());
|
||||||
unsigned occupiedBytes () const throw ();
|
unsigned occupiedBytes () const epics_throws (());
|
||||||
unsigned copyOutBytes ( epicsInt8 *pBuf, unsigned nBytes ) throw ();
|
unsigned copyOutBytes ( epicsInt8 *pBuf, unsigned nBytes ) epics_throws (());
|
||||||
unsigned removeBytes ( unsigned nBytes ) throw ();
|
unsigned removeBytes ( unsigned nBytes ) epics_throws (());
|
||||||
void pushLastComBufReceived ( comBuf & ) throw ();
|
void pushLastComBufReceived ( comBuf & ) epics_throws (());
|
||||||
void clear () throw ();
|
void clear () epics_throws (());
|
||||||
epicsInt8 popInt8 () throw ( comBuf::insufficentBytesAvailable );
|
epicsInt8 popInt8 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsUInt8 popUInt8 () throw ( comBuf::insufficentBytesAvailable );
|
epicsUInt8 popUInt8 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsInt16 popInt16 () throw ( comBuf::insufficentBytesAvailable );
|
epicsInt16 popInt16 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsUInt16 popUInt16 () throw ( comBuf::insufficentBytesAvailable );
|
epicsUInt16 popUInt16 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsInt32 popInt32 () throw ( comBuf::insufficentBytesAvailable );
|
epicsInt32 popInt32 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsUInt32 popUInt32 () throw ( comBuf::insufficentBytesAvailable );
|
epicsUInt32 popUInt32 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsFloat32 popFloat32 () throw ( comBuf::insufficentBytesAvailable );
|
epicsFloat32 popFloat32 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsFloat64 popFloat64 () throw ( comBuf::insufficentBytesAvailable );
|
epicsFloat64 popFloat64 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
void popString ( epicsOldString * ) throw ( comBuf::insufficentBytesAvailable );
|
void popString ( epicsOldString * ) epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
private:
|
private:
|
||||||
tsDLList < comBuf > bufs;
|
tsDLList < comBuf > bufs;
|
||||||
comBufMemoryManager & comBufMemMgr;
|
comBufMemoryManager & comBufMemMgr;
|
||||||
unsigned nBytesPending;
|
unsigned nBytesPending;
|
||||||
epicsUInt16 multiBufferPopUInt16 () throw ( comBuf::insufficentBytesAvailable );
|
epicsUInt16 multiBufferPopUInt16 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
epicsUInt32 multiBufferPopUInt32 () throw ( comBuf::insufficentBytesAvailable );
|
epicsUInt32 multiBufferPopUInt32 () epics_throws (( comBuf::insufficentBytesAvailable ));
|
||||||
void removeAndDestroyBuf ( comBuf & ) throw ();
|
void removeAndDestroyBuf ( comBuf & ) epics_throws (());
|
||||||
comQueRecv ( const comQueRecv & ) throw ();
|
comQueRecv ( const comQueRecv & ) epics_throws (());
|
||||||
comQueRecv & operator = ( const comQueRecv & ) throw ();
|
comQueRecv & operator = ( const comQueRecv & ) epics_throws (());
|
||||||
};
|
};
|
||||||
|
|
||||||
inline unsigned comQueRecv::occupiedBytes () const
|
inline unsigned comQueRecv::occupiedBytes () const
|
||||||
throw ()
|
epics_throws (())
|
||||||
{
|
{
|
||||||
return this->nBytesPending;
|
return this->nBytesPending;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline epicsInt8 comQueRecv::popInt8 ()
|
inline epicsInt8 comQueRecv::popInt8 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
return static_cast < epicsInt8 > ( this->popUInt8() );
|
return static_cast < epicsInt8 > ( this->popUInt8() );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline epicsInt16 comQueRecv::popInt16 ()
|
inline epicsInt16 comQueRecv::popInt16 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
return static_cast < epicsInt16 > ( this->popInt8() << 8u
|
return static_cast < epicsInt16 > ( this->popInt8() << 8u
|
||||||
| this->popInt8() << 0u );
|
| this->popInt8() << 0u );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline epicsInt32 comQueRecv::popInt32 ()
|
inline epicsInt32 comQueRecv::popInt32 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
epicsInt32 tmp ;
|
epicsInt32 tmp ;
|
||||||
tmp = this->popInt8() << 24u;
|
tmp = this->popInt8() << 24u;
|
||||||
@@ -87,7 +89,7 @@ inline epicsInt32 comQueRecv::popInt32 ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline epicsFloat32 comQueRecv::popFloat32 ()
|
inline epicsFloat32 comQueRecv::popFloat32 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
epicsFloat32 tmp;
|
epicsFloat32 tmp;
|
||||||
epicsUInt8 wire[ sizeof ( tmp ) ];
|
epicsUInt8 wire[ sizeof ( tmp ) ];
|
||||||
@@ -100,7 +102,7 @@ inline epicsFloat32 comQueRecv::popFloat32 ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline epicsFloat64 comQueRecv::popFloat64 ()
|
inline epicsFloat64 comQueRecv::popFloat64 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
epicsFloat64 tmp;
|
epicsFloat64 tmp;
|
||||||
epicsUInt8 wire[ sizeof ( tmp ) ];
|
epicsUInt8 wire[ sizeof ( tmp ) ];
|
||||||
@@ -113,7 +115,7 @@ inline epicsFloat64 comQueRecv::popFloat64 ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline epicsUInt8 comQueRecv::popUInt8 ()
|
inline epicsUInt8 comQueRecv::popUInt8 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
comBuf * pComBuf = this->bufs.first ();
|
comBuf * pComBuf = this->bufs.first ();
|
||||||
if ( ! pComBuf ) {
|
if ( ! pComBuf ) {
|
||||||
@@ -129,7 +131,7 @@ inline epicsUInt8 comQueRecv::popUInt8 ()
|
|||||||
|
|
||||||
// optimization here complicates this function somewhat
|
// optimization here complicates this function somewhat
|
||||||
inline epicsUInt16 comQueRecv::popUInt16 ()
|
inline epicsUInt16 comQueRecv::popUInt16 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
comBuf *pComBuf = this->bufs.first ();
|
comBuf *pComBuf = this->bufs.first ();
|
||||||
if ( ! pComBuf ) {
|
if ( ! pComBuf ) {
|
||||||
@@ -155,7 +157,7 @@ inline epicsUInt16 comQueRecv::popUInt16 ()
|
|||||||
|
|
||||||
// optimization here complicates this function somewhat
|
// optimization here complicates this function somewhat
|
||||||
inline epicsUInt32 comQueRecv::popUInt32 ()
|
inline epicsUInt32 comQueRecv::popUInt32 ()
|
||||||
throw ( comBuf::insufficentBytesAvailable )
|
epics_throws (( comBuf::insufficentBytesAvailable ))
|
||||||
{
|
{
|
||||||
comBuf *pComBuf = this->bufs.first ();
|
comBuf *pComBuf = this->bufs.first ();
|
||||||
if ( ! pComBuf ) {
|
if ( ! pComBuf ) {
|
||||||
|
|||||||
+14
-14
@@ -81,18 +81,18 @@ const char cacNillBytes [] =
|
|||||||
};
|
};
|
||||||
|
|
||||||
comQueSend::comQueSend ( wireSendAdapter & wireIn,
|
comQueSend::comQueSend ( wireSendAdapter & wireIn,
|
||||||
comBufMemoryManager & comBufMemMgrIn ) throw () :
|
comBufMemoryManager & comBufMemMgrIn ) epics_throws (()) :
|
||||||
comBufMemMgr ( comBufMemMgrIn ), wire ( wireIn ),
|
comBufMemMgr ( comBufMemMgrIn ), wire ( wireIn ),
|
||||||
nBytesPending ( 0u )
|
nBytesPending ( 0u )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
comQueSend::~comQueSend () throw ()
|
comQueSend::~comQueSend () epics_throws (())
|
||||||
{
|
{
|
||||||
this->clear ();
|
this->clear ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::clear () throw ()
|
void comQueSend::clear () epics_throws (())
|
||||||
{
|
{
|
||||||
comBuf *pBuf;
|
comBuf *pBuf;
|
||||||
|
|
||||||
@@ -109,7 +109,7 @@ void comQueSend::clear () throw ()
|
|||||||
assert ( this->nBytesPending == 0 );
|
assert ( this->nBytesPending == 0 );
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::clearUncommitted () throw ()
|
void comQueSend::clearUncommitted () epics_throws (())
|
||||||
{
|
{
|
||||||
while ( this->pFirstUncommited.valid() ) {
|
while ( this->pFirstUncommited.valid() ) {
|
||||||
tsDLIter < comBuf > next = this->pFirstUncommited;
|
tsDLIter < comBuf > next = this->pFirstUncommited;
|
||||||
@@ -129,32 +129,32 @@ void comQueSend::clearUncommitted () throw ()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::copy_dbr_string ( const void *pValue, unsigned nElem ) throw ()
|
void comQueSend::copy_dbr_string ( const void *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( static_cast <const dbr_string_t *> ( pValue ), nElem );
|
this->push ( static_cast <const dbr_string_t *> ( pValue ), nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::copy_dbr_short ( const void *pValue, unsigned nElem ) throw ()
|
void comQueSend::copy_dbr_short ( const void *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( static_cast <const dbr_short_t *> ( pValue ), nElem );
|
this->push ( static_cast <const dbr_short_t *> ( pValue ), nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::copy_dbr_float ( const void *pValue, unsigned nElem ) throw ()
|
void comQueSend::copy_dbr_float ( const void *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( static_cast <const dbr_float_t *> ( pValue ), nElem );
|
this->push ( static_cast <const dbr_float_t *> ( pValue ), nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::copy_dbr_char ( const void *pValue, unsigned nElem ) throw ()
|
void comQueSend::copy_dbr_char ( const void *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( static_cast <const dbr_char_t *> ( pValue ), nElem );
|
this->push ( static_cast <const dbr_char_t *> ( pValue ), nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::copy_dbr_long ( const void *pValue, unsigned nElem ) throw ()
|
void comQueSend::copy_dbr_long ( const void *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( static_cast <const dbr_long_t *> ( pValue ), nElem );
|
this->push ( static_cast <const dbr_long_t *> ( pValue ), nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::copy_dbr_double ( const void *pValue, unsigned nElem ) throw ()
|
void comQueSend::copy_dbr_double ( const void *pValue, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( static_cast <const dbr_double_t *> ( pValue ), nElem );
|
this->push ( static_cast <const dbr_double_t *> ( pValue ), nElem );
|
||||||
}
|
}
|
||||||
@@ -201,7 +201,7 @@ const comQueSend::copyFunc_t comQueSend::dbrCopyVector [39] = {
|
|||||||
0 // DBR_CLASS_NAME
|
0 // DBR_CLASS_NAME
|
||||||
};
|
};
|
||||||
|
|
||||||
comBuf * comQueSend::popNextComBufToSend () throw ()
|
comBuf * comQueSend::popNextComBufToSend () epics_throws (())
|
||||||
{
|
{
|
||||||
comBuf *pBuf = this->bufs.get ();
|
comBuf *pBuf = this->bufs.get ();
|
||||||
if ( pBuf ) {
|
if ( pBuf ) {
|
||||||
@@ -225,7 +225,7 @@ void comQueSend::insertRequestHeader (
|
|||||||
ca_uint16_t request, ca_uint32_t payloadSize,
|
ca_uint16_t request, ca_uint32_t payloadSize,
|
||||||
ca_uint16_t dataType, ca_uint32_t nElem, ca_uint32_t cid,
|
ca_uint16_t dataType, ca_uint32_t nElem, ca_uint32_t cid,
|
||||||
ca_uint32_t requestDependent, bool v49Ok )
|
ca_uint32_t requestDependent, bool v49Ok )
|
||||||
throw ( cacChannel::outOfBounds )
|
epics_throws (( cacChannel::outOfBounds ))
|
||||||
{
|
{
|
||||||
this->beginMsg ();
|
this->beginMsg ();
|
||||||
if ( payloadSize < 0xffff && nElem < 0xffff ) {
|
if ( payloadSize < 0xffff && nElem < 0xffff ) {
|
||||||
@@ -254,7 +254,7 @@ void comQueSend::insertRequestHeader (
|
|||||||
void comQueSend::insertRequestWithPayLoad (
|
void comQueSend::insertRequestWithPayLoad (
|
||||||
ca_uint16_t request, unsigned dataType, ca_uint32_t nElem,
|
ca_uint16_t request, unsigned dataType, ca_uint32_t nElem,
|
||||||
ca_uint32_t cid, ca_uint32_t requestDependent, const void * pPayload,
|
ca_uint32_t cid, ca_uint32_t requestDependent, const void * pPayload,
|
||||||
bool v49Ok ) throw ( cacChannel::outOfBounds )
|
bool v49Ok ) epics_throws (( cacChannel::outOfBounds ))
|
||||||
{
|
{
|
||||||
if ( ! this->dbr_type_ok ( dataType ) ) {
|
if ( ! this->dbr_type_ok ( dataType ) ) {
|
||||||
throw cacChannel::badType();
|
throw cacChannel::badType();
|
||||||
@@ -299,7 +299,7 @@ void comQueSend::insertRequestWithPayLoad (
|
|||||||
this->commitMsg ();
|
this->commitMsg ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void comQueSend::commitMsg () throw ()
|
void comQueSend::commitMsg () epics_throws (())
|
||||||
{
|
{
|
||||||
while ( this->pFirstUncommited.valid() ) {
|
while ( this->pFirstUncommited.valid() ) {
|
||||||
this->nBytesPending += this->pFirstUncommited->uncommittedBytes ();
|
this->nBytesPending += this->pFirstUncommited->uncommittedBytes ();
|
||||||
|
|||||||
+40
-40
@@ -40,56 +40,56 @@
|
|||||||
//
|
//
|
||||||
class comQueSend {
|
class comQueSend {
|
||||||
public:
|
public:
|
||||||
comQueSend ( wireSendAdapter &, comBufMemoryManager & ) throw ();
|
comQueSend ( wireSendAdapter &, comBufMemoryManager & ) epics_throws (());
|
||||||
~comQueSend () throw ();
|
~comQueSend () epics_throws (());
|
||||||
void clear () throw ();
|
void clear () epics_throws (());
|
||||||
void beginMsg () throw ();
|
void beginMsg () epics_throws (());
|
||||||
void commitMsg () throw ();
|
void commitMsg () epics_throws (());
|
||||||
unsigned occupiedBytes () const throw ();
|
unsigned occupiedBytes () const epics_throws (());
|
||||||
bool flushEarlyThreshold ( unsigned nBytesThisMsg ) const throw ();
|
bool flushEarlyThreshold ( unsigned nBytesThisMsg ) const epics_throws (());
|
||||||
bool flushBlockThreshold ( unsigned nBytesThisMsg ) const throw ();
|
bool flushBlockThreshold ( unsigned nBytesThisMsg ) const epics_throws (());
|
||||||
bool dbr_type_ok ( unsigned type ) throw ();
|
bool dbr_type_ok ( unsigned type ) epics_throws (());
|
||||||
void pushUInt16 ( const ca_uint16_t value ) throw ();
|
void pushUInt16 ( const ca_uint16_t value ) epics_throws (());
|
||||||
void pushUInt32 ( const ca_uint32_t value ) throw ();
|
void pushUInt32 ( const ca_uint32_t value ) epics_throws (());
|
||||||
void pushFloat32 ( const ca_float32_t value ) throw ();
|
void pushFloat32 ( const ca_float32_t value ) epics_throws (());
|
||||||
void pushString ( const char *pVal, unsigned nChar ) throw ();
|
void pushString ( const char *pVal, unsigned nChar ) epics_throws (());
|
||||||
void insertRequestHeader (
|
void insertRequestHeader (
|
||||||
ca_uint16_t request, ca_uint32_t payloadSize,
|
ca_uint16_t request, ca_uint32_t payloadSize,
|
||||||
ca_uint16_t dataType, ca_uint32_t nElem, ca_uint32_t cid,
|
ca_uint16_t dataType, ca_uint32_t nElem, ca_uint32_t cid,
|
||||||
ca_uint32_t requestDependent, bool v49Ok )
|
ca_uint32_t requestDependent, bool v49Ok )
|
||||||
throw ( cacChannel::outOfBounds );
|
epics_throws (( cacChannel::outOfBounds ));
|
||||||
void insertRequestWithPayLoad (
|
void insertRequestWithPayLoad (
|
||||||
ca_uint16_t request, unsigned dataType, ca_uint32_t nElem,
|
ca_uint16_t request, unsigned dataType, ca_uint32_t nElem,
|
||||||
ca_uint32_t cid, ca_uint32_t requestDependent,
|
ca_uint32_t cid, ca_uint32_t requestDependent,
|
||||||
const void * pPayload, bool v49Ok )
|
const void * pPayload, bool v49Ok )
|
||||||
throw ( cacChannel::outOfBounds );
|
epics_throws (( cacChannel::outOfBounds ));
|
||||||
void push_dbr_type ( unsigned type, const void *pVal, unsigned nElem ) throw ();
|
void push_dbr_type ( unsigned type, const void *pVal, unsigned nElem ) epics_throws (());
|
||||||
comBuf * popNextComBufToSend () throw ();
|
comBuf * popNextComBufToSend () epics_throws (());
|
||||||
private:
|
private:
|
||||||
comBufMemoryManager & comBufMemMgr;
|
comBufMemoryManager & comBufMemMgr;
|
||||||
tsDLList < comBuf > bufs;
|
tsDLList < comBuf > bufs;
|
||||||
tsDLIter < comBuf > pFirstUncommited;
|
tsDLIter < comBuf > pFirstUncommited;
|
||||||
wireSendAdapter & wire;
|
wireSendAdapter & wire;
|
||||||
unsigned nBytesPending;
|
unsigned nBytesPending;
|
||||||
void copy_dbr_string ( const void *pValue, unsigned nElem ) throw ();
|
void copy_dbr_string ( const void *pValue, unsigned nElem ) epics_throws (());
|
||||||
void copy_dbr_short ( const void *pValue, unsigned nElem ) throw ();
|
void copy_dbr_short ( const void *pValue, unsigned nElem ) epics_throws (());
|
||||||
void copy_dbr_float ( const void *pValue, unsigned nElem ) throw ();
|
void copy_dbr_float ( const void *pValue, unsigned nElem ) epics_throws (());
|
||||||
void copy_dbr_char ( const void *pValue, unsigned nElem ) throw ();
|
void copy_dbr_char ( const void *pValue, unsigned nElem ) epics_throws (());
|
||||||
void copy_dbr_long ( const void *pValue, unsigned nElem ) throw ();
|
void copy_dbr_long ( const void *pValue, unsigned nElem ) epics_throws (());
|
||||||
void copy_dbr_double ( const void *pValue, unsigned nElem ) throw ();
|
void copy_dbr_double ( const void *pValue, unsigned nElem ) epics_throws (());
|
||||||
void pushComBuf ( comBuf & ) throw ();
|
void pushComBuf ( comBuf & ) epics_throws (());
|
||||||
typedef void ( comQueSend::*copyFunc_t ) (
|
typedef void ( comQueSend::*copyFunc_t ) (
|
||||||
const void *pValue, unsigned nElem );
|
const void *pValue, unsigned nElem );
|
||||||
static const copyFunc_t dbrCopyVector [39];
|
static const copyFunc_t dbrCopyVector [39];
|
||||||
|
|
||||||
void clearUncommitted () throw ();
|
void clearUncommitted () epics_throws (());
|
||||||
|
|
||||||
//
|
//
|
||||||
// visual C++ versions 6 & 7 do not allow out of
|
// visual C++ versions 6 & 7 do not allow out of
|
||||||
// class member template function definition
|
// class member template function definition
|
||||||
//
|
//
|
||||||
template < class T >
|
template < class T >
|
||||||
inline void push ( const T *pVal, const unsigned nElem ) throw ()
|
inline void push ( const T *pVal, const unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
comBuf * pLastBuf = this->bufs.last ();
|
comBuf * pLastBuf = this->bufs.last ();
|
||||||
unsigned nCopied;
|
unsigned nCopied;
|
||||||
@@ -113,7 +113,7 @@ private:
|
|||||||
// class member template function definition
|
// class member template function definition
|
||||||
//
|
//
|
||||||
template < class T >
|
template < class T >
|
||||||
inline void push ( const T & val ) throw ()
|
inline void push ( const T & val ) epics_throws (())
|
||||||
{
|
{
|
||||||
comBuf * pComBuf = this->bufs.last ();
|
comBuf * pComBuf = this->bufs.last ();
|
||||||
if ( pComBuf && pComBuf->push ( val ) ) {
|
if ( pComBuf && pComBuf->push ( val ) ) {
|
||||||
@@ -124,13 +124,13 @@ private:
|
|||||||
this->pushComBuf ( *pComBuf );
|
this->pushComBuf ( *pComBuf );
|
||||||
}
|
}
|
||||||
|
|
||||||
comQueSend ( const comQueSend & ) throw ();
|
comQueSend ( const comQueSend & ) epics_throws (());
|
||||||
comQueSend & operator = ( const comQueSend & ) throw ();
|
comQueSend & operator = ( const comQueSend & ) epics_throws (());
|
||||||
};
|
};
|
||||||
|
|
||||||
extern const char cacNillBytes[];
|
extern const char cacNillBytes[];
|
||||||
|
|
||||||
inline bool comQueSend::dbr_type_ok ( unsigned type ) throw ()
|
inline bool comQueSend::dbr_type_ok ( unsigned type ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( type >= ( sizeof ( this->dbrCopyVector ) / sizeof ( this->dbrCopyVector[0] ) ) ) {
|
if ( type >= ( sizeof ( this->dbrCopyVector ) / sizeof ( this->dbrCopyVector[0] ) ) ) {
|
||||||
return false;
|
return false;
|
||||||
@@ -141,34 +141,34 @@ inline bool comQueSend::dbr_type_ok ( unsigned type ) throw ()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comQueSend::pushUInt16 ( const ca_uint16_t value ) throw ()
|
inline void comQueSend::pushUInt16 ( const ca_uint16_t value ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( value );
|
this->push ( value );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comQueSend::pushUInt32 ( const ca_uint32_t value ) throw ()
|
inline void comQueSend::pushUInt32 ( const ca_uint32_t value ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( value );
|
this->push ( value );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comQueSend::pushFloat32 ( const ca_float32_t value ) throw ()
|
inline void comQueSend::pushFloat32 ( const ca_float32_t value ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( value );
|
this->push ( value );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comQueSend::pushString ( const char *pVal, unsigned nChar ) throw ()
|
inline void comQueSend::pushString ( const char *pVal, unsigned nChar ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->push ( pVal, nChar );
|
this->push ( pVal, nChar );
|
||||||
}
|
}
|
||||||
|
|
||||||
// it is assumed that dbr_type_ok() was called prior to calling this routine
|
// it is assumed that dbr_type_ok() was called prior to calling this routine
|
||||||
// to check the type code
|
// to check the type code
|
||||||
inline void comQueSend::push_dbr_type ( unsigned type, const void *pVal, unsigned nElem ) throw ()
|
inline void comQueSend::push_dbr_type ( unsigned type, const void *pVal, unsigned nElem ) epics_throws (())
|
||||||
{
|
{
|
||||||
( this->*dbrCopyVector [type] ) ( pVal, nElem );
|
( this->*dbrCopyVector [type] ) ( pVal, nElem );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comQueSend::pushComBuf ( comBuf & cb ) throw ()
|
inline void comQueSend::pushComBuf ( comBuf & cb ) epics_throws (())
|
||||||
{
|
{
|
||||||
this->bufs.add ( cb );
|
this->bufs.add ( cb );
|
||||||
if ( ! this->pFirstUncommited.valid() ) {
|
if ( ! this->pFirstUncommited.valid() ) {
|
||||||
@@ -176,22 +176,22 @@ inline void comQueSend::pushComBuf ( comBuf & cb ) throw ()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
inline unsigned comQueSend::occupiedBytes () const throw ()
|
inline unsigned comQueSend::occupiedBytes () const epics_throws (())
|
||||||
{
|
{
|
||||||
return this->nBytesPending;
|
return this->nBytesPending;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comQueSend::flushBlockThreshold ( unsigned nBytesThisMsg ) const throw ()
|
inline bool comQueSend::flushBlockThreshold ( unsigned nBytesThisMsg ) const epics_throws (())
|
||||||
{
|
{
|
||||||
return ( this->nBytesPending + nBytesThisMsg > 16 * comBuf::capacityBytes () );
|
return ( this->nBytesPending + nBytesThisMsg > 16 * comBuf::capacityBytes () );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool comQueSend::flushEarlyThreshold ( unsigned nBytesThisMsg ) const throw ()
|
inline bool comQueSend::flushEarlyThreshold ( unsigned nBytesThisMsg ) const epics_throws (())
|
||||||
{
|
{
|
||||||
return ( this->nBytesPending + nBytesThisMsg > 4 * comBuf::capacityBytes () );
|
return ( this->nBytesPending + nBytesThisMsg > 4 * comBuf::capacityBytes () );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void comQueSend::beginMsg () throw ()
|
inline void comQueSend::beginMsg () epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->pFirstUncommited.valid() ) {
|
if ( this->pFirstUncommited.valid() ) {
|
||||||
this->clearUncommitted ();
|
this->clearUncommitted ();
|
||||||
|
|||||||
@@ -30,7 +30,7 @@
|
|||||||
#include "ipAddrToAsciiAsynchronous.h"
|
#include "ipAddrToAsciiAsynchronous.h"
|
||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "epicsMutex.h"
|
#include "epicsMutex.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
class cac;
|
class cac;
|
||||||
class callbackMutex;
|
class callbackMutex;
|
||||||
|
|||||||
+1
-1
@@ -35,7 +35,7 @@
|
|||||||
#include "tsDLList.h"
|
#include "tsDLList.h"
|
||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "epicsMutex.h"
|
#include "epicsMutex.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
#ifdef nciuh_restore_epicsExportSharedSymbols
|
#ifdef nciuh_restore_epicsExportSharedSymbols
|
||||||
# define epicsExportSharedSymbols
|
# define epicsExportSharedSymbols
|
||||||
|
|||||||
+1
-1
@@ -27,7 +27,7 @@
|
|||||||
#define netIOh
|
#define netIOh
|
||||||
|
|
||||||
#include "nciu.h"
|
#include "nciu.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
// SUN PRO generates multiply defined symbols if the baseNMIU
|
// SUN PRO generates multiply defined symbols if the baseNMIU
|
||||||
// destructor is virtual (therefore it is protected).
|
// destructor is virtual (therefore it is protected).
|
||||||
|
|||||||
+1
-1
@@ -33,7 +33,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
#ifdef oldAccessh_restore_epicsExportSharedSymbols
|
#ifdef oldAccessh_restore_epicsExportSharedSymbols
|
||||||
# define epicsExportSharedSymbols
|
# define epicsExportSharedSymbols
|
||||||
|
|||||||
@@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
#include "tsDLList.h"
|
#include "tsDLList.h"
|
||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
#ifdef repeaterClienth_restore_epicsExportSharedSymbols
|
#ifdef repeaterClienth_restore_epicsExportSharedSymbols
|
||||||
# define epicsExportSharedSymbols
|
# define epicsExportSharedSymbols
|
||||||
|
|||||||
+1
-1
@@ -35,7 +35,7 @@
|
|||||||
#include "tsFreeList.h"
|
#include "tsFreeList.h"
|
||||||
#include "resourceLib.h"
|
#include "resourceLib.h"
|
||||||
#include "epicsEvent.h"
|
#include "epicsEvent.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
#ifdef syncGrouph_restore_epicsExportSharedSymbols
|
#ifdef syncGrouph_restore_epicsExportSharedSymbols
|
||||||
# define epicsExportSharedSymbols
|
# define epicsExportSharedSymbols
|
||||||
|
|||||||
+2
-2
@@ -139,7 +139,7 @@ void tcpSendThread::run ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
unsigned tcpiiu::sendBytes ( const void *pBuf,
|
unsigned tcpiiu::sendBytes ( const void *pBuf,
|
||||||
unsigned nBytesInBuf ) throw ()
|
unsigned nBytesInBuf ) epics_throws (())
|
||||||
{
|
{
|
||||||
int status;
|
int status;
|
||||||
unsigned nBytes = 0u;
|
unsigned nBytes = 0u;
|
||||||
@@ -202,7 +202,7 @@ unsigned tcpiiu::sendBytes ( const void *pBuf,
|
|||||||
return nBytes;
|
return nBytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned tcpiiu::recvBytes ( void * pBuf, unsigned nBytesInBuf ) throw ()
|
unsigned tcpiiu::recvBytes ( void * pBuf, unsigned nBytesInBuf ) epics_throws (())
|
||||||
{
|
{
|
||||||
if ( this->state != iiucs_connected &&
|
if ( this->state != iiucs_connected &&
|
||||||
this->state != iiucs_clean_shutdown ) {
|
this->state != iiucs_clean_shutdown ) {
|
||||||
|
|||||||
@@ -170,8 +170,8 @@ private:
|
|||||||
bool recvProcessPostponedFlush;
|
bool recvProcessPostponedFlush;
|
||||||
|
|
||||||
bool processIncoming ( epicsGuard < callbackMutex > & );
|
bool processIncoming ( epicsGuard < callbackMutex > & );
|
||||||
unsigned sendBytes ( const void *pBuf, unsigned nBytesInBuf ) throw ();
|
unsigned sendBytes ( const void *pBuf, unsigned nBytesInBuf ) epics_throws (());
|
||||||
unsigned recvBytes ( void *pBuf, unsigned nBytesInBuf ) throw ();
|
unsigned recvBytes ( void *pBuf, unsigned nBytesInBuf ) epics_throws (());
|
||||||
void connect ();
|
void connect ();
|
||||||
const char * pHostName () const;
|
const char * pHostName () const;
|
||||||
|
|
||||||
|
|||||||
@@ -24,6 +24,7 @@
|
|||||||
#include "epicsMutex.h"
|
#include "epicsMutex.h"
|
||||||
#include "epicsGuard.h"
|
#include "epicsGuard.h"
|
||||||
#include "epicsThread.h"
|
#include "epicsThread.h"
|
||||||
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
// This class exists for the purpose of avoiding file scope
|
// This class exists for the purpose of avoiding file scope
|
||||||
// object chicken and egg problems. It implements thread safe
|
// object chicken and egg problems. It implements thread safe
|
||||||
@@ -41,33 +42,33 @@ public:
|
|||||||
// inline func def required by visual c++ 7
|
// inline func def required by visual c++ 7
|
||||||
class reference {
|
class reference {
|
||||||
public:
|
public:
|
||||||
reference ( TYPE & tIn ) throw () :
|
reference ( TYPE & tIn ) epics_throws (()) :
|
||||||
instance ( tIn )
|
instance ( tIn )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
~reference () throw ()
|
~reference () epics_throws (())
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
TYPE * operator -> () throw ()
|
TYPE * operator -> () epics_throws (())
|
||||||
{
|
{
|
||||||
return & this->instance;
|
return & this->instance;
|
||||||
}
|
}
|
||||||
|
|
||||||
const TYPE * operator -> () const throw ()
|
const TYPE * operator -> () const epics_throws (())
|
||||||
{
|
{
|
||||||
typename epicsSingleton<TYPE>::reference & ref =
|
typename epicsSingleton<TYPE>::reference & ref =
|
||||||
const_cast < typename epicsSingleton<TYPE>::reference & > ( *this );
|
const_cast < typename epicsSingleton<TYPE>::reference & > ( *this );
|
||||||
return ref.operator -> ();
|
return ref.operator -> ();
|
||||||
}
|
}
|
||||||
|
|
||||||
TYPE & operator * () throw ()
|
TYPE & operator * () epics_throws (())
|
||||||
{
|
{
|
||||||
return * this->operator -> ();
|
return * this->operator -> ();
|
||||||
}
|
}
|
||||||
|
|
||||||
const TYPE & operator * () const throw ()
|
const TYPE & operator * () const epics_throws (())
|
||||||
{
|
{
|
||||||
return * this->operator -> ();
|
return * this->operator -> ();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,6 +66,7 @@
|
|||||||
#include <new>
|
#include <new>
|
||||||
#include "string.h"
|
#include "string.h"
|
||||||
|
|
||||||
|
#include "cxxCompilerDependencies.h"
|
||||||
#include "epicsMutex.h"
|
#include "epicsMutex.h"
|
||||||
#include "epicsGuard.h"
|
#include "epicsGuard.h"
|
||||||
|
|
||||||
@@ -85,21 +86,21 @@ template < class T, unsigned N = 0x400,
|
|||||||
class tsFreeList {
|
class tsFreeList {
|
||||||
public:
|
public:
|
||||||
tsFreeList ()
|
tsFreeList ()
|
||||||
throw ();
|
epics_throws (());
|
||||||
~tsFreeList ()
|
~tsFreeList ()
|
||||||
throw ();
|
epics_throws (());
|
||||||
void * allocate ( size_t size )
|
void * allocate ( size_t size )
|
||||||
throw ( std::bad_alloc );
|
epics_throws (( std::bad_alloc ));
|
||||||
void release ( void * p )
|
void release ( void * p )
|
||||||
throw ();
|
epics_throws (());
|
||||||
void release ( void * p, size_t size )
|
void release ( void * p, size_t size )
|
||||||
throw ();
|
epics_throws (());
|
||||||
private:
|
private:
|
||||||
MUTEX mutex;
|
MUTEX mutex;
|
||||||
tsFreeListItem < T > * pFreeList;
|
tsFreeListItem < T > * pFreeList;
|
||||||
tsFreeListChunk < T, N > * pChunkList;
|
tsFreeListChunk < T, N > * pChunkList;
|
||||||
void * allocateFromNewChunk ()
|
void * allocateFromNewChunk ()
|
||||||
throw ( std::bad_alloc );
|
epics_throws (( std::bad_alloc ));
|
||||||
};
|
};
|
||||||
|
|
||||||
template < class T >
|
template < class T >
|
||||||
@@ -117,10 +118,10 @@ struct tsFreeListChunk {
|
|||||||
|
|
||||||
template < class T, unsigned N, class MUTEX >
|
template < class T, unsigned N, class MUTEX >
|
||||||
inline tsFreeList < T, N, MUTEX > :: tsFreeList ()
|
inline tsFreeList < T, N, MUTEX > :: tsFreeList ()
|
||||||
throw () : pFreeList ( 0 ), pChunkList ( 0 ) {}
|
epics_throws (()) : pFreeList ( 0 ), pChunkList ( 0 ) {}
|
||||||
|
|
||||||
template < class T, unsigned N, class MUTEX >
|
template < class T, unsigned N, class MUTEX >
|
||||||
tsFreeList < T, N, MUTEX > :: ~tsFreeList () throw ()
|
tsFreeList < T, N, MUTEX > :: ~tsFreeList () epics_throws (())
|
||||||
{
|
{
|
||||||
while ( tsFreeListChunk < T, N > *pChunk = this->pChunkList ) {
|
while ( tsFreeListChunk < T, N > *pChunk = this->pChunkList ) {
|
||||||
this->pChunkList = this->pChunkList->pNext;
|
this->pChunkList = this->pChunkList->pNext;
|
||||||
@@ -130,7 +131,7 @@ tsFreeList < T, N, MUTEX > :: ~tsFreeList () throw ()
|
|||||||
|
|
||||||
template < class T, unsigned N, class MUTEX >
|
template < class T, unsigned N, class MUTEX >
|
||||||
void * tsFreeList < T, N, MUTEX >::allocate ( size_t size )
|
void * tsFreeList < T, N, MUTEX >::allocate ( size_t size )
|
||||||
throw ( std::bad_alloc )
|
epics_throws (( std::bad_alloc ))
|
||||||
{
|
{
|
||||||
if ( size != sizeof ( T ) || N == 0u || tsFreeListDebugBypass ) {
|
if ( size != sizeof ( T ) || N == 0u || tsFreeListDebugBypass ) {
|
||||||
void * p = ::operator new ( size );
|
void * p = ::operator new ( size );
|
||||||
@@ -150,7 +151,7 @@ void * tsFreeList < T, N, MUTEX >::allocate ( size_t size )
|
|||||||
|
|
||||||
template < class T, unsigned N, class MUTEX >
|
template < class T, unsigned N, class MUTEX >
|
||||||
void * tsFreeList < T, N, MUTEX >::allocateFromNewChunk ()
|
void * tsFreeList < T, N, MUTEX >::allocateFromNewChunk ()
|
||||||
throw ( std::bad_alloc )
|
epics_throws (( std::bad_alloc ))
|
||||||
{
|
{
|
||||||
tsFreeListChunk < T, N > * pChunk =
|
tsFreeListChunk < T, N > * pChunk =
|
||||||
new tsFreeListChunk < T, N >;
|
new tsFreeListChunk < T, N >;
|
||||||
@@ -170,7 +171,7 @@ void * tsFreeList < T, N, MUTEX >::allocateFromNewChunk ()
|
|||||||
|
|
||||||
template < class T, unsigned N, class MUTEX >
|
template < class T, unsigned N, class MUTEX >
|
||||||
void tsFreeList < T, N, MUTEX >::release ( void * pCadaver, size_t size )
|
void tsFreeList < T, N, MUTEX >::release ( void * pCadaver, size_t size )
|
||||||
throw ()
|
epics_throws (())
|
||||||
{
|
{
|
||||||
if ( size != sizeof ( T ) ) {
|
if ( size != sizeof ( T ) ) {
|
||||||
tsFreeListMemSetDelete ( pCadaver, size );
|
tsFreeListMemSetDelete ( pCadaver, size );
|
||||||
@@ -183,7 +184,7 @@ void tsFreeList < T, N, MUTEX >::release ( void * pCadaver, size_t size )
|
|||||||
|
|
||||||
template < class T, unsigned N, class MUTEX >
|
template < class T, unsigned N, class MUTEX >
|
||||||
void tsFreeList < T, N, MUTEX >::release ( void * pCadaver )
|
void tsFreeList < T, N, MUTEX >::release ( void * pCadaver )
|
||||||
throw ()
|
epics_throws (())
|
||||||
{
|
{
|
||||||
if ( N == 0u || tsFreeListDebugBypass ) {
|
if ( N == 0u || tsFreeListDebugBypass ) {
|
||||||
tsFreeListMemSetDelete ( pCadaver, sizeof ( T ) );
|
tsFreeListMemSetDelete ( pCadaver, sizeof ( T ) );
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ epicsTimerNotify::~epicsTimerNotify () {}
|
|||||||
|
|
||||||
void epicsTimerNotify::show ( unsigned /* level */ ) const {}
|
void epicsTimerNotify::show ( unsigned /* level */ ) const {}
|
||||||
|
|
||||||
epicsTimerForC::epicsTimerForC ( timerQueue &queue, epicsTimerCallback pCBIn, void *pPrivateIn ) throw () :
|
epicsTimerForC::epicsTimerForC ( timerQueue &queue, epicsTimerCallback pCBIn, void *pPrivateIn ) epics_throws (()) :
|
||||||
timer ( queue ), pCallBack ( pCBIn ), pPrivate ( pPrivateIn )
|
timer ( queue ), pCallBack ( pCBIn ), pPrivate ( pPrivateIn )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -70,7 +70,7 @@ epicsTimerQueueActiveForC::~epicsTimerQueueActiveForC ()
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void epicsTimerQueueActiveForC::release () throw ()
|
void epicsTimerQueueActiveForC::release () epics_throws (())
|
||||||
{
|
{
|
||||||
epicsSingleton < timerQueueActiveMgr >::reference pMgr =
|
epicsSingleton < timerQueueActiveMgr >::reference pMgr =
|
||||||
timerQueueMgrEPICS;
|
timerQueueMgrEPICS;
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ template class tsFreeList < timer, 0x20 >;
|
|||||||
# pragma warning ( pop )
|
# pragma warning ( pop )
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
timer::timer ( timerQueue & queueIn ) throw ():
|
timer::timer ( timerQueue & queueIn ) epics_throws (()):
|
||||||
queue ( queueIn ), curState ( stateLimbo ), pNotify ( 0 )
|
queue ( queueIn ), curState ( stateLimbo ), pNotify ( 0 )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,7 +22,7 @@
|
|||||||
#include "epicsSingleton.h"
|
#include "epicsSingleton.h"
|
||||||
#include "tsDLList.h"
|
#include "tsDLList.h"
|
||||||
#include "epicsTimer.h"
|
#include "epicsTimer.h"
|
||||||
#include "cxxCompilerDepPlacementDelete.h"
|
#include "cxxCompilerDependencies.h"
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
# define debugPrintf(ARGSINPAREN) printf ARGSINPAREN
|
# define debugPrintf(ARGSINPAREN) printf ARGSINPAREN
|
||||||
@@ -45,7 +45,7 @@ public:
|
|||||||
void operator delete ( void *, tsFreeList < timer, 0x20 > & );
|
void operator delete ( void *, tsFreeList < timer, 0x20 > & );
|
||||||
#endif
|
#endif
|
||||||
protected:
|
protected:
|
||||||
timer ( class timerQueue & ) throw ();
|
timer ( class timerQueue & ) epics_throws (());
|
||||||
~timer ();
|
~timer ();
|
||||||
timerQueue & queue;
|
timerQueue & queue;
|
||||||
private:
|
private:
|
||||||
@@ -69,7 +69,7 @@ struct epicsTimerForC : public epicsTimerNotify, public timer {
|
|||||||
public:
|
public:
|
||||||
void destroy ();
|
void destroy ();
|
||||||
protected:
|
protected:
|
||||||
epicsTimerForC ( timerQueue &, epicsTimerCallback, void *pPrivateIn ) throw ();
|
epicsTimerForC ( timerQueue &, epicsTimerCallback, void *pPrivateIn ) epics_throws (());
|
||||||
~epicsTimerForC ();
|
~epicsTimerForC ();
|
||||||
void * operator new ( size_t size, tsFreeList < epicsTimerForC, 0x20 > & );
|
void * operator new ( size_t size, tsFreeList < epicsTimerForC, 0x20 > & );
|
||||||
#ifdef CXX_PLACEMENT_DELETE
|
#ifdef CXX_PLACEMENT_DELETE
|
||||||
@@ -199,7 +199,7 @@ struct epicsTimerQueueActiveForC : public timerQueueActive,
|
|||||||
public tsDLNode < epicsTimerQueueActiveForC > {
|
public tsDLNode < epicsTimerQueueActiveForC > {
|
||||||
public:
|
public:
|
||||||
epicsTimerQueueActiveForC ( bool okToShare, unsigned priority );
|
epicsTimerQueueActiveForC ( bool okToShare, unsigned priority );
|
||||||
void release () throw();
|
void release () epics_throws (());
|
||||||
void * operator new ( size_t );
|
void * operator new ( size_t );
|
||||||
void operator delete ( void * );
|
void operator delete ( void * );
|
||||||
protected:
|
protected:
|
||||||
|
|||||||
Reference in New Issue
Block a user