Class ScadaFieldDescriptor
Maintains the (field name, field PV) pairs for the data sets formed of device
PVs. For example, such data sets are supported by ScadaRecord.
ScadaFieldDescriptor objects are immutable.
Ported from XAL on Jul 15, 2014.
· Jonathan M. Freed
- Since:
- Dec 18, 2009
- Author:
- Christopher K. Allen
-
Nested Class Summary
Nested classes/interfaces inherited from class xal.smf.scada.XalPvDescriptor
XalPvDescriptor.IPvDescriptor -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionScadaFieldDescriptor(String strFldNm, Class<?> clsType, String strHandleRb) Create a newScadaFieldDescriptorobject.ScadaFieldDescriptor(String strFldNm, Class<?> clsType, String strHndRb, String strHndSet) Create a newScadaFieldDescriptorobject.ScadaFieldDescriptor(String strFldNm, XalPvDescriptor pvdFld) Create a newScadaFieldDescriptorobject built from an existing.PvDescriptor -
Method Summary
Modifier and TypeMethodDescriptionprotected Objectclone()Returns a deep copy of this object.Return the data field's name.static ScadaFieldDescriptormakeFieldDescriptor(String strFldName, Class<?> clsScada) This method returns data of theannotation meta data.AScada.Fieldstatic ScadaFieldDescriptormakeFieldDescriptor(String strName, AScada.Field annFld) Creates aScadaStruct$ScadaFieldDescriptorobject according to the specifications in the given arguments.static ScadaFieldDescriptor[]makeFieldDescriptorArray(Class<?> clsScada) This method returns the field descriptor objects for each field in the SCADA data structure, only here it is returned as an array.static List<ScadaFieldDescriptor>makeFieldDescriptorList(Class<?> clsScada) This method returns meta-data of theannotation used to identify fields in data structures as Supervisory Control And Data Acquisition (SCADA) fields.AScada.Fieldstatic ScadaFieldDescriptor[]makeFieldDescriptors(Class<? extends AScada.Record> clsRec) Creates and returns an array ofScadaFieldDescriptorobjects each of which is described in the given annotation class.AScadatoString()Write out the contents of this field descriptor as a string.Methods inherited from class xal.smf.scada.XalPvDescriptor
getPvType, getRbHandle, getSetHandle, isControllable
-
Field Details
-
strFldNm
Name of the data field in the SCADA data structure
-
-
Constructor Details
-
ScadaFieldDescriptor
Create a newScadaFieldDescriptorobject built from an existing.PvDescriptor- Parameters:
strFldNm- the name of the data fieldpvdFld- channel access PV descriptor of data field- Since:
- Dec 18, 2009
-
ScadaFieldDescriptor
Create a newScadaFieldDescriptorobject.- Parameters:
strFldNm- the name of the data fieldclsType- the class type of the data fieldstrHandleRb- the handle of the read back channel- Since:
- Jan 13, 2010
-
ScadaFieldDescriptor
Create a newScadaFieldDescriptorobject. This descriptor represents a process variable that can be controlled and has a "set value" channel.- Parameters:
strFldNm- the name of the data fieldclsType- the class type of the data fieldstrHndRb- the handle of the read back channelstrHndSet- the handle of the set PV value channel- Since:
- Jan 13, 2010
-
-
Method Details
-
makeFieldDescriptorArray
This method returns the field descriptor objects for each field in the SCADA data structure, only here it is returned as an array. This is a convenience method which simply calls
then converts the result into an array.makeFieldDescriptorList(Class)- Parameters:
clsScada- class type of the SCADA data structure- Returns:
- an array of descriptor objects, one for each data structure field
- Since:
- Mar 1, 2011
-
makeFieldDescriptorList
This method returns meta-data of the
annotation used to identify fields in data structures as Supervisory Control And Data Acquisition (SCADA) fields. The meta-data is taken from each field annotation and is used to populate aAScada.FieldScadaFieldDescriptorobject. The sum of all annotation data for each field is returned as a list of field descriptors.This whole mechanism of
ScadaFieldDescriptorusage is (hopefully) going to be eradicated. It is too clumsy and the Java Annotation mechanism seems more appropriate.- Parameters:
clsScada- class type which is meant to be a SCADA data structure It must be annotated withAScada- Returns:
- list of field descriptors describing all the field in the data structure used for SCADA.
- Since:
- Feb 16, 2011
-
makeFieldDescriptor
This method returns data of the
annotation meta data. The meta data is used to identify fields in data structures as Supervisory Control And Data Acquisition (SCADA) fields. The meta-data is taken the annotation around the field and entered into a new aAScada.FieldScadaFieldDescriptorobject.- Parameters:
strFldName- field name within the SCADA data structureclsScada- class type which is meant to be a SCADA data structure It must be annotated withAScada- Returns:
- field descriptor describing the field meta-data in the data
structure or
nullif the field is not a SCADA type // * @throws SecurityException the given field is not public // - Throws:
NoSuchFieldException- there is no field of the given name- Since:
- Mar 1, 2011
-
makeFieldDescriptor
Creates aScadaStruct$ScadaFieldDescriptorobject according to the specifications in the given arguments.- Parameters:
strName- SCADA field nameannFld- SCADA field annotation- Returns:
- SCADA field descriptor corresponding to the given arguments
- Since:
- Mar 3, 2011
-
makeFieldDescriptors
Creates and returns an array ofScadaFieldDescriptorobjects each of which is described in the given annotation class.AScada- Parameters:
clsRec- class type annotated with theAScada.Recordannotation- Returns:
- array of field descriptors described in the above annotation
- Since:
- Oct 3, 2011
-
getFieldName
Return the data field's name.- Returns:
- name of the data field
- Since:
- Dec 18, 2009
-
toString
Write out the contents of this field descriptor as a string.- Overrides:
toStringin classXalPvDescriptor- Returns:
- description of the field descriptor
- Since:
- Mar 3, 2011
- See Also:
-
clone
Returns a deep copy of this object.- Overrides:
clonein classXalPvDescriptor- Throws:
CloneNotSupportedException- Since:
- Apr 19, 2012
- See Also:
-