Building Controls Virtual Test Bed
|
This is the driver class in ADInterfaceMCC. More...
Classes | |
enum | ADInterfaceMCCApplicationTag |
enumeration object, contains all the BACnet application tags specified in ADInterfaceMCC More... | |
Public Member Functions | |
String | getReadPropertyBinaryPath () |
Returns the ADReader.jar binary file path. More... | |
String | getWritePropertyBinaryPath () |
Returns the ADWriter.jar binary file path. More... | |
ArrayList < ADInterfaceMCCObjectType > | parseADInterfaceMCCObjectType (final String s) throws ParserConfigurationException, SAXException, IOException |
Parse the configuration file and generate an ArrayList that contains the xml content as specified in the configuration file, it is called in readXMLConfigurationFile (see adInterfaceMCC.util.ADInterfaceMCC). More... | |
ArrayList< ProcessBuilder > | getProcesses (ArrayList< ADInterfaceMCCObjectType > prop_arr) |
Prepare the process to be executed. More... | |
void | validateApplicationTag (final String s) throws IllegalArgumentException |
Application tag validation. More... | |
void | validateXMLFile (final String xmlfile, final Schema schema) throws SAXException, FileNotFoundException,IOException |
XMLfile validation. More... | |
Schema | loadSchema (final String name) throws SAXException |
Load schema. More... | |
Static Public Member Functions | |
static ArrayList< Integer > | saveDuplicates (ArrayList< Integer > arlList) |
Removes duplicates from an array list of integers. More... | |
Static Protected Member Functions | |
static String | toString (String arg) throws IllegalArgumentException |
Gets a string representation of the enumeration. More... | |
Static Private Attributes | |
static final String | bcvtbhome = System.getenv("BCVTB_HOME") |
String that points to root directory of the BCVTB. More... | |
static final String | LS = System.getProperty("line.separator") |
System-dependent line separator. More... | |
static final String | FS = System.getProperty("file.separator") |
System-dependent file separator. More... | |
static final String | osName = System.getProperty("os.name") |
Name of the operating system. More... | |
static final String | cmd = "java" |
Name of the command to run the process. More... | |
static final String | cmdOptions = "-jar" |
Options of the command to run the process. More... | |
This is the driver class in ADInterfaceMCC.
It is used mainly by ADInterfaceMCC.java. It is used to process ADInterfaceMCCObjectType read from configuration file, and to translate them to processes, to be executed by ADInterfaceMCC-stack command.
This class is called by ADInterfaceMCC(seeadInterfaceMCC.util.ADInterfaceMCC ) to get reading and writing processes, ADInterfaceMCCReader(see adInterfaceMCC.actor.ADInterfaceMCCReader) to get processes to read property from ADInterfaceMCC device, and by ADInterfaceMCCWrtier (see adInterfaceMCC.actor.ADInterfaceMCCWriter) to get processes to write property to ADInterfaceMCC device.
Definition at line 110 of file ADInterfaceMCCDeviceManager.java.
|
inline |
Prepare the process to be executed.
prop_arr | arraylist with elements of ADInterfaceMCCObjectType. |
Definition at line 236 of file ADInterfaceMCCDeviceManager.java.
References adInterfaceMCC.util.ADInterfaceMCCDeviceManager.cmd, adInterfaceMCC.util.ADInterfaceMCCDeviceManager.cmdOptions, adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getReadPropertyBinaryPath(), adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getWritePropertyBinaryPath(), and i.
|
inline |
Returns the ADReader.jar binary file path.
This function is called in prepareProcesses, (see adInterfaceMCC.util.ADInterfaceMCCDeviceManager).
Definition at line 146 of file ADInterfaceMCCDeviceManager.java.
References adInterfaceMCC.util.ADInterfaceMCCDeviceManager.bcvtbhome, and adInterfaceMCC.util.ADInterfaceMCCDeviceManager.FS.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getProcesses().
|
inline |
Returns the ADWriter.jar binary file path.
This function is called in prepareProcesses, (see adInterfaceMCC.util.ADInterfaceMCCDeviceManager).
Definition at line 162 of file ADInterfaceMCCDeviceManager.java.
References adInterfaceMCC.util.ADInterfaceMCCDeviceManager.bcvtbhome, and adInterfaceMCC.util.ADInterfaceMCCDeviceManager.FS.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getProcesses().
|
inline |
Load schema.
It is called in validateSyntax(), (see adInterfaceMCC.actor.ADInterfaceMCCReader and adInterfaceMCC.actor.ADInterfaceMCCWriter).
name | file name of the schema file. |
SAXException | if error occurs in schema loading process. |
Definition at line 383 of file ADInterfaceMCCDeviceManager.java.
References adInterfaceMCC.util.ADInterfaceMCCDeviceManager.LS.
|
inline |
Parse the configuration file and generate an ArrayList that contains the xml content as specified in the configuration file, it is called in readXMLConfigurationFile (see adInterfaceMCC.util.ADInterfaceMCC).
s | path of configuration file. |
ParserConfigurationException | if errors occur in configuring parser. |
SAXException | if errors occur in parsing configuration file. |
IOException | if I/O exception occurs in parsing configuration file. |
Definition at line 179 of file ADInterfaceMCCDeviceManager.java.
References adInterfaceMCC.util.ADInterfaceMCCDeviceManager.LS.
|
inlinestatic |
Removes duplicates from an array list of integers.
arlList | array list with duplicated entries. |
Definition at line 212 of file ADInterfaceMCCDeviceManager.java.
|
inlinestaticprotected |
Gets a string representation of the enumeration.
arg | enumeration to be converted to string. |
IllegalArgumentException | if the argument is not ADInterfaceMCCApplicationTag . |
Definition at line 280 of file ADInterfaceMCCDeviceManager.java.
References i, adInterfaceMCC.util.ADInterfaceMCCDeviceManager.LS, r, and strLen.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.validateApplicationTag().
|
inline |
Application tag validation.
It is called in validateAttributes(), (see adInterfaceMCC.util.ADInterfaceMCC).
s | string read from configuration file. |
IllegalArgumentException | if s is not part of ADInterfaceMCCApplicationTag enum type. |
Definition at line 323 of file ADInterfaceMCCDeviceManager.java.
References adInterfaceMCC.util.ADInterfaceMCCDeviceManager.LS, and adInterfaceMCC.util.ADInterfaceMCCDeviceManager.toString().
|
inline |
XMLfile validation.
It is called in validateSyntax(), (see adInterfaceMCC.actor.ADInterfaceMCCReader and adInterfaceMCC.actor.ADInterfaceMCCWriter).
xmlfile | file name of the xmlfile. |
schema | schema used to validate the xmlfile. |
FileNotFoundException | if either xmlfile or schema couldn't be found. |
SAXException | if xmlfile is not properly written. |
IOException | if error occurs when reading xmlfile or schema. |
Definition at line 348 of file ADInterfaceMCCDeviceManager.java.
References adInterfaceMCC.util.ADInterfaceMCCDeviceManager.LS, and source.
|
staticprivate |
String that points to root directory of the BCVTB.
Definition at line 114 of file ADInterfaceMCCDeviceManager.java.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getReadPropertyBinaryPath(), and adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getWritePropertyBinaryPath().
|
staticprivate |
Name of the command to run the process.
Definition at line 126 of file ADInterfaceMCCDeviceManager.java.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getProcesses().
|
staticprivate |
Options of the command to run the process.
Definition at line 129 of file ADInterfaceMCCDeviceManager.java.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getProcesses().
|
staticprivate |
System-dependent file separator.
Definition at line 120 of file ADInterfaceMCCDeviceManager.java.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getReadPropertyBinaryPath(), and adInterfaceMCC.util.ADInterfaceMCCDeviceManager.getWritePropertyBinaryPath().
|
staticprivate |
System-dependent line separator.
Definition at line 117 of file ADInterfaceMCCDeviceManager.java.
Referenced by adInterfaceMCC.util.ADInterfaceMCCDeviceManager.loadSchema(), adInterfaceMCC.util.ADInterfaceMCCDeviceManager.parseADInterfaceMCCObjectType(), adInterfaceMCC.util.ADInterfaceMCCDeviceManager.toString(), adInterfaceMCC.util.ADInterfaceMCCDeviceManager.validateApplicationTag(), and adInterfaceMCC.util.ADInterfaceMCCDeviceManager.validateXMLFile().
|
staticprivate |
Name of the operating system.
Definition at line 123 of file ADInterfaceMCCDeviceManager.java.