fix API interface definition, and revise documentation.

This commit is contained in:
Guobao Shen
2012-11-04 09:23:32 -05:00
parent 20be57c460
commit d324f4f532
4 changed files with 54 additions and 68 deletions
+6 -6
View File
@@ -49,7 +49,7 @@ public:
* Get the function field.
* @return The pvString or null if no function field.
*/
PVStringPtr & getFunction() {return pvFunction;}
PVStringPtr getFunction() {return pvFunction;}
/**
* Attach a pvTimeStamp.
* @param pvTimeStamp The pvTimeStamp that will be attached.
@@ -66,27 +66,27 @@ public:
* Get the pvStructure.
* @return PVStructurePtr.
*/
PVStructurePtr & getPVStructure(){return pvNTNameValue;}
PVStructurePtr getPVStructure(){return pvNTNameValue;}
/**
* Get the timeStamp.
* @return PVStructurePtr which may be null.
*/
PVStructurePtr & getTimeStamp(){return pvTimeStamp;}
PVStructurePtr getTimeStamp(){return pvTimeStamp;}
/**
* Get the alarm.
* @return PVStructurePtr which may be null.
*/
PVStructurePtr & getAlarm() {return pvAlarm;}
PVStructurePtr getAlarm() {return pvAlarm;}
/**
* Get the string array on names.
* @return The array of names.
*/
PVStringArrayPtr & getNames() {return pvNames;}
PVStringArrayPtr getNames() {return pvNames;}
/**
* Get the string array on values.
* @return The array of values.
*/
PVStringArrayPtr & getValues() {return pvValues;}
PVStringArrayPtr getValues() {return pvValues;}
private:
NTNameValue(PVStructurePtr const & pvStructure);
PVStructurePtr pvNTNameValue;
+2 -2
View File
@@ -136,13 +136,13 @@ size_t NTTable::getNumberValues()
return pvLabel->getLength();
}
FieldConstPtr & NTTable::getField(size_t index)
FieldConstPtr NTTable::getField(size_t index)
{
FieldConstPtrArray fields = pvNTTable->getStructure()->getFields();
return fields[index + offsetFields];
}
PVFieldPtr & NTTable::getPVField(size_t index)
PVFieldPtr NTTable::getPVField(size_t index)
{
PVFieldPtrArray pvFields = pvNTTable->getPVFields();
return pvFields[index+offsetFields];
+7 -7
View File
@@ -52,7 +52,7 @@ public:
* Get the function field.
* @return The pvString or null if no function field.
*/
PVStringPtr & getFunction() {return pvFunction;}
PVStringPtr getFunction() {return pvFunction;}
/**
* Attach a pvTimeStamp.
* @param pvTimeStamp The pvTimeStamp that will be attached.
@@ -69,22 +69,22 @@ public:
* Get the pvStructure.
* @return PVStructurePtr.
*/
PVStructurePtr & getPVStructure(){return pvNTTable;}
PVStructurePtr getPVStructure(){return pvNTTable;}
/**
* Get the timeStamp.
* @return PVStructurePtr which may be null.
*/
PVStructurePtr & getTimeStamp(){return pvTimeStamp;}
PVStructurePtr getTimeStamp(){return pvTimeStamp;}
/**
* Get the alarm.
* @return PVStructurePtr which may be null.
*/
PVStructurePtr & getAlarm() {return pvAlarm;}
PVStructurePtr getAlarm() {return pvAlarm;}
/**
* Get the label field.
* @return The pvStringArray for the label.
*/
PVStringArrayPtr & getLabel() {return pvLabel;}
PVStringArrayPtr getLabel() {return pvLabel;}
/**
* Get the the number of fields that follow the label field.
* @return The number of fields.
@@ -95,13 +95,13 @@ public:
* @param index The index of the field desired.
* @return The FieldConstPtr for the field.
*/
FieldConstPtr & getField(size_t index);
FieldConstPtr getField(size_t index);
/**
* Get the PVField for a field that follows the label field.
* @param index The index of the field desired.
* @return The PVFieldPtr for the field.
*/
PVFieldPtr & getPVField(size_t index);
PVFieldPtr getPVField(size_t index);
private:
NTTable(PVStructurePtr const & pvStructure);
PVStructurePtr pvNTTable;