public class SMLUtils
extends org.vast.xml.XMLBindingsUtils
Helper class providing a version agnostic access to SensorML object readers and writers. This class delegates to version specific readers/writers.
| Modifier and Type | Field and Description |
|---|---|
static String |
IC |
static String |
SENSORML |
static String |
V2_0 |
| Constructor and Description |
|---|
SMLUtils(String version)
Creates this helper for the specified SensorML version
|
| Modifier and Type | Method and Description |
|---|---|
String |
getVersion(org.vast.xml.DOMHelper dom,
Element smlElt)
Logic to guess SensorML version from namespace
|
static void |
loadRegistry() |
AbstractProcess |
readProcess(org.vast.xml.DOMHelper dom,
Element processElt)
Reads a SensorML process from a DOM element
|
AbstractProcess |
readProcess(InputStream is)
Reads a SensorML process from an InputStream
The root element must be of one of the types derived from AbstractProcess
|
Element |
writeProcess(org.vast.xml.DOMHelper dom,
AbstractProcess process)
Serializes a SensorML process to a DOM element
|
void |
writeProcess(OutputStream os,
AbstractProcess process,
boolean indent)
Serializes a SensorMl process to an OutputStream
|
public static final String IC
public static final String SENSORML
public static final String V2_0
public SMLUtils(String version)
version - public static void loadRegistry()
public AbstractProcess readProcess(org.vast.xml.DOMHelper dom, Element processElt) throws org.vast.xml.XMLReaderException
dom - DOM helper wrapping the XML document to read fromprocessElt - DOM element to read from. Must be of one of the types derived from AbstractProcessorg.vast.xml.XMLReaderException - if an error occured while reading the XMLpublic AbstractProcess readProcess(InputStream is) throws org.vast.xml.XMLReaderException
is - Input stream to read fromorg.vast.xml.XMLReaderException - if an error occured while reading the XMLpublic Element writeProcess(org.vast.xml.DOMHelper dom, AbstractProcess process) throws org.vast.xml.XMLWriterException
dom - DOM helper wrapping the XMl document to write toprocess - Process object to serializeorg.vast.xml.XMLWriterException - if an error occurs while generating the DOM treepublic void writeProcess(OutputStream os, AbstractProcess process, boolean indent) throws org.vast.xml.XMLWriterException, IOException
os - Output stream to write toprocess - Process object to serializeindent - Set to true to indent the outputorg.vast.xml.XMLWriterException - if an error occurs while generating the XML contentIOException - if an error occurs while writing to output the streamCopyright © 2016 VAST Team / Sensia Software LLC. All rights reserved.