edu.sc.seis.sod.subsetter
Class AbstractScriptSubsetter

java.lang.Object
  extended by edu.sc.seis.sod.subsetter.AbstractScriptSubsetter
All Implemented Interfaces:
SodElement, Subsetter
Direct Known Subclasses:
AvailableDataScript, ChannelScript, EventChannelScript, EventStationScript, EventVectorScript, NetworkScript, OriginScript, RequestGeneratorScript, RequestScript, SacHeaderScript, SeismogramScript, StationScript, VectorAvailableDataScript, VectorRequestGeneratorScript, VectorRequestScript, VectorScript

public class AbstractScriptSubsetter
extends java.lang.Object
implements Subsetter


Field Summary
protected  org.w3c.dom.Element config
           
protected  javax.script.ScriptEngine engine
           
protected static javax.script.ScriptEngineManager factory
           
protected  java.lang.String script
           
protected  java.lang.String scriptType
           
 
Constructor Summary
AbstractScriptSubsetter(org.w3c.dom.Element config)
           
 
Method Summary
static java.lang.String cleanScript(java.lang.String script)
           
protected  StringTree eval()
           
protected  java.lang.Object preeval()
           
protected  java.lang.Object pullResult(java.lang.Object result)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

script

protected java.lang.String script

config

protected org.w3c.dom.Element config

scriptType

protected java.lang.String scriptType

engine

protected javax.script.ScriptEngine engine

factory

protected static javax.script.ScriptEngineManager factory
Constructor Detail

AbstractScriptSubsetter

public AbstractScriptSubsetter(org.w3c.dom.Element config)
Method Detail

preeval

protected java.lang.Object preeval()
                            throws java.lang.Exception
Throws:
java.lang.Exception

pullResult

protected java.lang.Object pullResult(java.lang.Object result)
                               throws java.lang.Exception
Throws:
java.lang.Exception

eval

protected StringTree eval()
                   throws java.lang.Exception
Throws:
java.lang.Exception

cleanScript

public static java.lang.String cleanScript(java.lang.String script)