php.java.script
Class PhpJavaBridgeRunnerScriptContext

java.lang.Object
  extended by php.java.script.PhpScriptContextDecorator
      extended by php.java.script.PhpJavaBridgeRunnerScriptContext
All Implemented Interfaces:
ScriptContext, IContext, IManaged, Invocable, IPhpScriptContext

public class PhpJavaBridgeRunnerScriptContext
extends PhpScriptContextDecorator

A decorator which enables secure (HTTPS) connections. Call engine.setContext(new PhpSecureScriptContext(engine.getContext())) before executing the engine.

Author:
jostb

Field Summary
 
Fields inherited from interface php.java.bridge.http.IContext
ENGINE_SCOPE, GLOBAL_SCOPE, JAVA_BRIDGE, PHP_PROCEDURE, SERVLET, SERVLET_CONFIG, SERVLET_CONTEXT, SERVLET_REQUEST, SERVLET_RESPONSE
 
Fields inherited from interface javax.script.ScriptContext
ENGINE_SCOPE, GLOBAL_SCOPE
 
Constructor Summary
PhpJavaBridgeRunnerScriptContext(ScriptContext ctx, JavaBridgeRunner httpServer)
          Create a new PhpCompiledScriptContext using an existing PhpScriptContext
 
Method Summary
 ContextServer getContextServer()
          Get the context server associated with this context, usually a HttpServer (JavaBridgeRunner) or a ContextServer from a ContextLoaderListener
 java.lang.String getSocketName()
          Return the socket name, for example 8080
 
Methods inherited from class php.java.script.PhpScriptContextDecorator
call, createContinuation, get, getAll, getAttribute, getAttribute, getAttributesScope, getBindings, getContinuation, getErrorWriter, getHttpServletRequest, getHttpServletResponse, getReader, getRealPath, getRedirectString, getRedirectString, getRedirectURL, getScopes, getServlet, getServletConfig, getServletContext, getWriter, init, onShutdown, put, putAll, remove, removeAttribute, setAttribute, setBindings, setContinuation, setErrorWriter, setReader, setWriter, startContinuation
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PhpJavaBridgeRunnerScriptContext

public PhpJavaBridgeRunnerScriptContext(ScriptContext ctx,
                                        JavaBridgeRunner httpServer)
Create a new PhpCompiledScriptContext using an existing PhpScriptContext

Parameters:
ctx - the script context to be decorated
Method Detail

getSocketName

public java.lang.String getSocketName()
Return the socket name, for example 8080

Specified by:
getSocketName in interface IContext
Overrides:
getSocketName in class PhpScriptContextDecorator
Returns:
the socket name

getContextServer

public ContextServer getContextServer()
Get the context server associated with this context, usually a HttpServer (JavaBridgeRunner) or a ContextServer from a ContextLoaderListener

Specified by:
getContextServer in interface IPhpScriptContext
Overrides:
getContextServer in class PhpScriptContextDecorator
Returns:
the ContextServer