php.java.script
Class PhpScriptEngineFactory

java.lang.Object
  extended by php.java.script.PhpScriptEngineFactory
All Implemented Interfaces:
ScriptEngineFactory
Direct Known Subclasses:
InvocablePhpScriptEngineFactory

public class PhpScriptEngineFactory
extends java.lang.Object
implements ScriptEngineFactory

Create a standalone PHP script engines.


Constructor Summary
PhpScriptEngineFactory()
          Create a new EngineFactory
 
Method Summary
 java.lang.String getEngineName()
          Retrieves the full name of the ScriptEngine.
 java.lang.String getEngineVersion()
          Retrieves the version of the Script Engine.
 java.util.List getExtensions()
          Retrieves an array of Strings which are file extensions tipically used for files containing scripts written in the language supported by the ScriptEngine.
 java.lang.String getLanguageName()
          Retrieves the name of the language supported by the ScriptEngine.
 java.lang.String getLanguageVersion()
          Retrieves the version of the language supported by the ScriptEngine.
 java.lang.String getMethodCallSyntax(java.lang.String obj, java.lang.String m, java.lang.String[] args)
          Return a syntax string for method calls
 java.util.List getMimeTypes()
          Retrieves an array of Strings containing MIME types describing the content which can be processed using the Script Engine.
 java.util.List getNames()
          Retrieves an array of short descriptive names such as {"javascript", "rhino"} describing the language supported by the Script Engine.
 java.lang.String getOutputStatement(java.lang.String toDisplay)
          Return the output syntax
 java.lang.Object getParameter(java.lang.String key)
          Retrieves an associated value for the specified key.
 java.lang.String getProgram(java.lang.String[] statements)
          Return the program syntax
 ScriptEngine getScriptEngine()
          Retrieves an instance of the associated ScriptEngine.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PhpScriptEngineFactory

public PhpScriptEngineFactory()
Create a new EngineFactory

Method Detail

getEngineName

public java.lang.String getEngineName()
Retrieves the full name of the ScriptEngine.

Specified by:
getEngineName in interface ScriptEngineFactory
Returns:
the name of the Script Engine

getEngineVersion

public java.lang.String getEngineVersion()
Retrieves the version of the Script Engine.

Specified by:
getEngineVersion in interface ScriptEngineFactory
Returns:
the version of the Script Engine

getLanguageName

public java.lang.String getLanguageName()
Retrieves the name of the language supported by the ScriptEngine.

Specified by:
getLanguageName in interface ScriptEngineFactory
Returns:
the name of the supported language

getLanguageVersion

public java.lang.String getLanguageVersion()
Retrieves the version of the language supported by the ScriptEngine.

Specified by:
getLanguageVersion in interface ScriptEngineFactory
Returns:
the version of the supported language

getExtensions

public java.util.List getExtensions()
Retrieves an array of Strings which are file extensions tipically used for files containing scripts written in the language supported by the ScriptEngine.

Specified by:
getExtensions in interface ScriptEngineFactory
Returns:
string array of supported file extensions

getMimeTypes

public java.util.List getMimeTypes()
Retrieves an array of Strings containing MIME types describing the content which can be processed using the Script Engine.

Specified by:
getMimeTypes in interface ScriptEngineFactory
Returns:
string array of MIME types

getNames

public java.util.List getNames()
Retrieves an array of short descriptive names such as {"javascript", "rhino"} describing the language supported by the Script Engine.

Specified by:
getNames in interface ScriptEngineFactory
Returns:
an array of short descriptive names describing the language supported by the ScriptEngine

getScriptEngine

public ScriptEngine getScriptEngine()
Retrieves an instance of the associated ScriptEngine.

Specified by:
getScriptEngine in interface ScriptEngineFactory
Returns:
an instance of the associated ScriptEngine

getParameter

public java.lang.Object getParameter(java.lang.String key)
Retrieves an associated value for the specified key. Returns null if the ScriptEngine does not have an associated value for the key.

Specified by:
getParameter in interface ScriptEngineFactory
Parameters:
key - The key
Returns:
associated value for the specified key

getMethodCallSyntax

public java.lang.String getMethodCallSyntax(java.lang.String obj,
                                            java.lang.String m,
                                            java.lang.String[] args)
Return a syntax string for method calls

Specified by:
getMethodCallSyntax in interface ScriptEngineFactory
Parameters:
obj - The call object
m - The methods
args - The arguments
Returns:
A syntax string

getOutputStatement

public java.lang.String getOutputStatement(java.lang.String toDisplay)
Return the output syntax

Specified by:
getOutputStatement in interface ScriptEngineFactory
Parameters:
toDisplay - The output string
Returns:
the output syntax

getProgram

public java.lang.String getProgram(java.lang.String[] statements)
Return the program syntax

Specified by:
getProgram in interface ScriptEngineFactory
Parameters:
statements - The statement sequence
Returns:
The program syntax