changes for new pvAccess API

This commit is contained in:
Marty Kraimer
2014-06-04 10:48:12 -04:00
parent a5fa17aca7
commit ca27cb5e3c
7 changed files with 222 additions and 276 deletions

View File

@@ -64,9 +64,8 @@ bool ExampleLink::init()
if(pvValue==NULL) {
return false;
}
ChannelAccess::shared_pointer channelAccess = getChannelAccess();
ChannelProvider::shared_pointer provider =
channelAccess->getProvider(providerName);
getChannelProviderRegistry()->getProvider(providerName);
if(provider==NULL) {
cout << getRecordName() << " provider "
<< providerName << " does not exist" << endl;
@@ -104,7 +103,7 @@ bool ExampleLink::init()
void ExampleLink::process()
{
status = Status::Ok;
channelGet->get(false);
channelGet->get();
event.wait();
timeStamp.getCurrent();
pvTimeStamp.set(timeStamp);
@@ -142,20 +141,23 @@ void ExampleLink::channelStateChange(
void ExampleLink::channelGetConnect(
const Status& status,
ChannelGet::shared_pointer const & channelGet,
PVStructure::shared_pointer const & pvStructure,
BitSet::shared_pointer const & bitSet)
StructureConstPtr const & structure)
{
this->status = status;
this->channelGet = channelGet;
this->getPVStructure = pvStructure;
event.signal();
}
void ExampleLink::getDone(
const Status& status,
ChannelGet::shared_pointer const & channelGet,
PVStructurePtr const & pvStructure,
BitSetPtr const & bitSet)
{
this->status = status;
getPVStructure = pvStructure;
this->bitSet = bitSet;
event.signal();
}
void ExampleLink::getDone(const Status& status)
{
this->status = status;
event.signal();
}
}}