本文整理汇总了C++中epicsGuard类的典型用法代码示例。如果您正苦于以下问题:C++ epicsGuard类的具体用法?C++ epicsGuard怎么用?C++ epicsGuard使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了epicsGuard类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: exception
void cac::exception (
epicsGuard < epicsMutex > & cbGuard,
epicsGuard < epicsMutex > & guard, int status,
const char * pContext, const char * pFileName, unsigned lineNo )
{
cbGuard.assertIdenticalMutex ( this->cbMutex );
guard.assertIdenticalMutex ( this->mutex );
this->notify.exception ( guard, status, pContext,
pFileName, lineNo );
}
示例2: beaconAnomalyNotify
void bhe::beaconAnomalyNotify ( epicsGuard < epicsMutex > & guard )
{
guard.assertIdenticalMutex ( this->mutex );
if ( this->pIIU ) {
this->pIIU->beaconAnomalyNotify ( guard );
}
}
示例3: installChan
void disconnectGovernorTimer::installChan (
epicsGuard < epicsMutex > & guard, nciu & chan )
{
guard.assertIdenticalMutex ( this->mutex );
this->chanList.add ( chan );
chan.channelNode::listMember = channelNode::cs_disconnGov;
}
示例4: registerSearchDest
void cac::registerSearchDest (
epicsGuard < epicsMutex > & guard,
SearchDest & req )
{
guard.assertIdenticalMutex ( this->mutex );
this->searchDestList.add ( req );
}
示例5: channelDeleteException
void dbSubscriptionIO::channelDeleteException (
epicsGuard < epicsMutex > & guard )
{
guard.assertIdenticalMutex ( this->mutex );
this->notify.exception ( guard, ECA_CHANDESTROY,
this->chan.pName(guard), this->type, this->count );
}
示例6: uninstallChan
void searchTimer::uninstallChan (
epicsGuard < epicsMutex > & cacGuard, nciu & chan )
{
cacGuard.assertIdenticalMutex ( this->mutex );
unsigned ulistmem =
static_cast <unsigned> ( chan.channelNode::listMember );
unsigned uReqBase =
static_cast <unsigned> ( channelNode::cs_searchReqPending0 );
if ( ulistmem == this->index + uReqBase ) {
this->chanListReqPending.remove ( chan );
}
else {
unsigned uRespBase =
static_cast <unsigned > (
channelNode::cs_searchRespPending0 );
if ( ulistmem == this->index + uRespBase ) {
this->chanListRespPending.remove ( chan );
}
else {
throw std::runtime_error (
"uninstalling channel search timer, but channel "
"state is wrong" );
}
}
chan.channelNode::listMember = channelNode::cs_none;
}
示例7: pushDatagramMsg
bool udpiiu::pushDatagramMsg ( epicsGuard < epicsMutex > & guard,
const caHdr & msg, const void * pExt, ca_uint16_t extsize )
{
guard.assertIdenticalMutex ( this->cacMutex );
ca_uint16_t alignedExtSize = static_cast <ca_uint16_t> (CA_MESSAGE_ALIGN ( extsize ));
arrayElementCount msgsize = sizeof ( caHdr ) + alignedExtSize;
/* fail out if max message size exceeded */
if ( msgsize >= sizeof ( this->xmitBuf ) - 7 ) {
return false;
}
if ( msgsize + this->nBytesInXmitBuf > sizeof ( this->xmitBuf ) ) {
return false;
}
caHdr * pbufmsg = ( caHdr * ) &this->xmitBuf[this->nBytesInXmitBuf];
*pbufmsg = msg;
if ( extsize ) {
memcpy ( pbufmsg + 1, pExt, extsize );
if ( extsize != alignedExtSize ) {
char *pDest = (char *) ( pbufmsg + 1 );
memset ( pDest + extsize, '\0', alignedExtSize - extsize );
}
}
AlignedWireRef < epicsUInt16 > ( pbufmsg->m_postsize ) = alignedExtSize;
this->nBytesInXmitBuf += msgsize;
return true;
}
示例8: selfTest
void cac::selfTest (
epicsGuard < epicsMutex > & guard ) const
{
guard.assertIdenticalMutex ( this->mutex );
this->chanTable.verify ();
this->ioTable.verify ();
this->beaconTable.verify ();
}
示例9: show
void udpiiu :: SearchDestUDP :: show (
epicsGuard < epicsMutex > & guard, unsigned level ) const
{
guard.assertIdenticalMutex ( _udpiiu.cacMutex );
char buf[64];
sockAddrToDottedIP ( &_destAddr.sa, buf, sizeof ( buf ) );
:: printf ( "UDP Search destination \"%s\"\n", buf );
}
示例10: initiateConnect
void cac::initiateConnect (
epicsGuard < epicsMutex > & guard,
nciu & chan, netiiu * & piiu )
{
guard.assertIdenticalMutex ( this->mutex );
assert ( this->pudpiiu );
this->pudpiiu->installNewChannel ( guard, chan, piiu );
}
示例11: flush
//
// set the push pending flag on all virtual circuits
//
void cac::flush ( epicsGuard < epicsMutex > & guard )
{
guard.assertIdenticalMutex ( this->mutex );
tsDLIter < tcpiiu > iter = this->circuitList.firstIter ();
while ( iter.valid () ) {
iter->flushRequest ( guard );
iter++;
}
}
示例12: show
void dbContextReadNotifyCache::show (
epicsGuard < epicsMutex > & guard, unsigned level ) const
{
guard.assertIdenticalMutex ( _mutex );
printf ( "dbContextReadNotifyCache\n" );
if ( level > 0 ) {
this->_allocator.show ( level - 1 );
}
}
示例13: disconnectChannel
void cac::disconnectChannel (
epicsGuard < epicsMutex > & cbGuard,
epicsGuard < epicsMutex > & guard, nciu & chan )
{
guard.assertIdenticalMutex ( this->mutex );
assert ( this->pudpiiu );
chan.disconnectAllIO ( cbGuard, guard );
chan.getPIIU(guard)->uninstallChan ( guard, chan );
this->pudpiiu->installDisconnectedChannel ( guard, chan );
chan.unresponsiveCircuitNotify ( cbGuard, guard );
}
示例14: unregisterIIU
void bhe::unregisterIIU (
epicsGuard < epicsMutex > & guard, tcpiiu & iiu )
{
guard.assertIdenticalMutex ( this->mutex );
if ( this->pIIU == & iiu ) {
this->pIIU = 0;
this->timeStamp = epicsTime();
this->averagePeriod = - DBL_MAX;
logBeacon ( "ui", this->averagePeriod, epicsTime::getCurrent () );
}
}
示例15: disconnectAllIO
void cac::disconnectAllIO (
epicsGuard < epicsMutex > & cbGuard,
epicsGuard < epicsMutex > & guard,
nciu & chan, tsDLList < baseNMIU > & ioList )
{
cbGuard.assertIdenticalMutex ( this->cbMutex );
guard.assertIdenticalMutex ( this->mutex );
char buf[128];
chan.getHostName ( guard, buf, sizeof ( buf ) );
tsDLIter < baseNMIU > pNetIO = ioList.firstIter();
while ( pNetIO.valid () ) {
tsDLIter < baseNMIU > pNext = pNetIO;
pNext++;
if ( ! pNetIO->isSubscription() ) {
this->ioTable.remove ( pNetIO->getId () );
}
pNetIO->exception ( guard, *this, ECA_DISCONN, buf );
pNetIO = pNext;
}
}