Xindice API

org.apache.xindice.server
Class SimpleScript

java.lang.Object
  |
  +--org.apache.xindice.util.SimpleConfigurable
        |
        +--org.apache.xindice.server.SimpleScriptComponent
              |
              +--org.apache.xindice.server.SimpleScript
All Implemented Interfaces:
Configurable, Disposable, KernelAccess, Named, Script, ScriptComponent, Versioning
Direct Known Subclasses:
GET, PUT

public class SimpleScript
extends SimpleScriptComponent
implements Script

SimpleScript is an extendable implementation of the Script and ScriptComponent interfaces. The only method that needs to be overriden when extending SimpleScript is the run method. SimpleScripts can also be added to Xindice's component list for access to Kernel functionality.


Fields inherited from class org.apache.xindice.server.SimpleScriptComponent
NAME, PACKAGE
 
Fields inherited from interface org.apache.xindice.server.Script
ACCESS_ADMIN, ACCESS_DESIGN, ACCESS_EXECUTE, ACCESS_NONE, ACCESS_READ, ACCESS_WRITE
 
Constructor Summary
SimpleScript()
           
 
Method Summary
 int getAccessMethods()
          getAccessMethods retrieves the access methods that someone executing this Script will require access to in order to actually run the Script.
 void run(Gateway gateway)
          run executes the Script, passing a Gateway object to it to serve as a resource provider and server gateway.
 
Methods inherited from class org.apache.xindice.server.SimpleScriptComponent
dispose, getName, getPackageName, getVersion, setKernel
 
Methods inherited from class org.apache.xindice.util.SimpleConfigurable
getConfig, setConfig
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.xindice.server.Versioning
getPackageName, getVersion
 
Methods inherited from interface org.apache.xindice.util.Named
getName
 

Constructor Detail

SimpleScript

public SimpleScript()
Method Detail

run

public void run(Gateway gateway)
Description copied from interface: Script
run executes the Script, passing a Gateway object to it to serve as a resource provider and server gateway.
Specified by:
run in interface Script
Following copied from interface: org.apache.xindice.server.Script
Parameters:
gateway - The Gateway object to process

getAccessMethods

public int getAccessMethods()
Description copied from interface: Script
getAccessMethods retrieves the access methods that someone executing this Script will require access to in order to actually run the Script. The returned value will be an ORed (|) result that includes all of the applicable access methods utilized.
Specified by:
getAccessMethods in interface Script
Following copied from interface: org.apache.xindice.server.Script
Returns:
The access methods

Xindice API

Copyright (c) 1999-2001 The Apache Software Foundation