Skip to main content
Package: com.phoenix_int.aserver.util.scriptwrapper.api Class Hierarchy
Implemented Interfaces
Declaration
Represents an XML file (not a file variable) used in a script wrapper, with access to the XML node values via XPath statements

Nested Class Summary

Nested classes/interfaces inherited from interface com.phoenix_int.aserver.util.scriptwrapper.api.ParseableFile

ParseableFile.Mode

Field Summary

Fields inherited from class com.phoenix_int.aserver.util.scriptwrapper.api.AbstractFile

encoding, fileName, mode, parser, templateFileName, wrapper

Constructor Summary

Method Summary

Methods inherited from class com.phoenix_int.aserver.util.scriptwrapper.api.AbstractFile

actionByMode, backup, close, delete, ensureFileParser, getEncoding, getRealFile, readTemplate, setEncoding, setEncoding, setFileToGenerateOrParse, setTempEmbedded, setTemplateFile, setVariable

Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Methods inherited from interface com.phoenix_int.aserver.util.scriptwrapper.api.ParseableFile

backup, close, delete, readTemplate, setFileToGenerateOrParse, setTempEmbedded, setTemplateFile, setVariable

Constructor Detail

XPathFile

Construct a new XPathFile Parameters:
  • wrapper - script wrapper object
  • mode - parser mode

Method Detail

addVariable

Add a variable to the wrapper. The transfer of variable values will be handled automatically during any call to generate(), parse(), or AbstractFile.readTemplate(). Parameters:
  • name - variable name
  • type - variable type
  • isInput - whether variable is an input
  • xpath - XPath expression
Throws:

newParser

Generate a new parser for the given file and mode Specified by:
  • newParser in class AbstractFile
Parameters:
  • rFile - The file to open
  • pmode - caching mode for underlying parser
Throws:
  • java.io.IOException

newParser

Allow a sub-class to form a parser using custom options/features, such as handling DTD and entities Parameters:
  • file -
Throws:
  • java.io.IOException
  • org.xml.sax.SAXException
  • javax.xml.parsers.ParserConfigurationException

getParser

Get the XPath parser Throws:
  • java.io.IOException

transferVars

Transfer values for variables that have been defined using methods from the concrete implementation, i.e.PHXRowFieldFile.defineVar(String, String, boolean, String) Variables defined using PHXScriptWrapperObject.addVariable(String, String, boolean) must be explicitly transferred using methods of the concrete implementation class Specified by:
  • transferVars in class AbstractFile
Throws:

transferArray

Transfer an array of values, either from the file to the variable, or vice-versa, depending on ParseableFile.Mode Parameters:
  • var - array variable
  • exp - XPath expression
Throws:

transferVar

Transfer a value, either from the file to the variable, or vice-versa, depending on ParseableFile.Mode Parameters:
  • var - variable
  • exp - XPath expression
Throws:

parse

Parse the output file Specified by:
  • parse in interface OutputFile
  • parse in interface OutputFile2
Throws:

setFileToParse

Set the file to be parsed Specified by:
  • setFileToParse in interface OutputFile
  • setFileToParse in interface OutputFile2
Parameters:
  • fileName - file name

generate

Generate the input file Specified by:
  • generate in interface InputFile
Throws:

setFileToGenerate

Set the file to be generated Specified by:
  • setFileToGenerate in interface InputFile
Parameters:
  • fileName - file name