28 #define epicsExportSharedSymbols 38 namespace epics {
namespace pvDatabase {
41 std::string
const & recordName)
46 addNestedStructure(
"argument")->
50 addNestedStructure(
"result") ->
54 PVStructurePtr pvStructure = pvDataCreate->createPVStructure(topStructure);
57 if(!pvRecord->init()) pvRecord.reset();
61 TraceRecord::TraceRecord(
62 std::string
const & recordName,
69 bool TraceRecord::init()
73 pvRecordName = pvStructure->getSubField<
PVString>(
"argument.recordName");
74 if(!pvRecordName)
return false;
75 pvLevel = pvStructure->getSubField<
PVInt>(
"argument.level");
76 if(!pvLevel)
return false;
77 pvResult = pvStructure->getSubField<
PVString>(
"result.status");
78 if(!pvResult)
return false;
82 void TraceRecord::process()
84 string name = pvRecordName->get();
85 PVRecordPtr pvRecord = PVDatabase::getMaster()->findRecord(name);
87 pvResult->put(name +
" not found");
90 pvRecord->setTraceLevel(pvLevel->get());
91 pvResult->put(
"success");
shared_ptr< T > static_pointer_cast(shared_ptr< U > const &r) BOOST_NOEXCEPT
TODO only here because of the Lockable.
std::tr1::shared_ptr< const Structure > StructureConstPtr
Base interface for a PVRecord.
std::tr1::shared_ptr< PVDataCreate > PVDataCreatePtr
PVString is special case, since it implements SerializableArray.
Trace activity of PVRecord.
FORCE_INLINE const FieldCreatePtr & getFieldCreate()
std::tr1::shared_ptr< PVRecord > PVRecordPtr
std::tr1::shared_ptr< TraceRecord > TraceRecordPtr
std::tr1::shared_ptr< PVStructure > PVStructurePtr
Class that holds the data for each possible scalar type.
std::tr1::shared_ptr< FieldCreate > FieldCreatePtr
FORCE_INLINE const PVDataCreatePtr & getPVDataCreate()