Skip navigation links

Oracle® Fusion Middleware Site Studio for External Applications Java API Reference
11g Release 1 (11.1.1)

E17273-02


oracle.stellent.wcm.client.script
Class ScriptableRequestContext

java.lang.Object
  extended by oracle.stellent.wcm.client.RequestContext
      extended by oracle.stellent.wcm.client.script.ScriptableRequestContext


public class ScriptableRequestContext
extends RequestContext

Request context for executing requests in memory


Constructor Summary
ScriptableRequestContext(ScriptableClientApplication clientApplication, java.lang.String contextPath, java.lang.String uri, java.security.Principal principal, java.io.Writer writer)
           
ScriptableRequestContext(ScriptableRequestContext parent, java.lang.String uri, java.io.Writer writer)
           

 

Method Summary
protected  void executePath(java.lang.String path, boolean forward)
          Execute the path
 java.lang.Object getAttribute(java.lang.String name)
          Retrieve an attribute value
 java.util.Set<java.lang.String> getAttributeNames()
          Retrieve the attribute names for the given scope
 ScriptableClientApplication getClientApplication()
           
 java.lang.String getContextPath()
           
 java.util.Map<java.lang.String,java.lang.String> getParameters()
           
 java.lang.String getRequestPath()
           
 java.security.Principal getUserPrincipal()
           
 java.io.Writer getWriter()
           
 void sendRedirect(java.lang.String path)
          Send a redirect
 void setAttribute(java.lang.String name, java.lang.Object value)
          Set an attribute value by name
 void setHeader(java.lang.String name, java.lang.String value)
          Set a response header

 

Methods inherited from class oracle.stellent.wcm.client.RequestContext
exposeObjects, forward, getParameter, getSiteContext, include, include, process, restoreObjects, setSiteContext

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

ScriptableRequestContext

public ScriptableRequestContext(ScriptableClientApplication clientApplication,
                                java.lang.String contextPath,
                                java.lang.String uri,
                                java.security.Principal principal,
                                java.io.Writer writer)
                         throws java.net.URISyntaxException
Throws:
java.net.URISyntaxException

ScriptableRequestContext

public ScriptableRequestContext(ScriptableRequestContext parent,
                                java.lang.String uri,
                                java.io.Writer writer)
                         throws java.net.URISyntaxException
Throws:
java.net.URISyntaxException

Method Detail

getClientApplication

public ScriptableClientApplication getClientApplication()

getWriter

public java.io.Writer getWriter()
                         throws java.io.IOException
Specified by:
getWriter in class RequestContext
Returns:
the writer for the given context
Throws:
java.io.IOException

setAttribute

public void setAttribute(java.lang.String name,
                         java.lang.Object value)
Set an attribute value by name
Specified by:
setAttribute in class RequestContext
Parameters:
name - the name
value - the value (null to remove)

getAttribute

public java.lang.Object getAttribute(java.lang.String name)
Retrieve an attribute value
Specified by:
getAttribute in class RequestContext
Parameters:
name - the name
Returns:
the value or null if not found

getAttributeNames

public java.util.Set<java.lang.String> getAttributeNames()
Retrieve the attribute names for the given scope
Specified by:
getAttributeNames in class RequestContext
Returns:
the set of attribute names

getParameters

public java.util.Map<java.lang.String,java.lang.String> getParameters()
Specified by:
getParameters in class RequestContext
Returns:
a map of all the request parameters

getContextPath

public java.lang.String getContextPath()
Specified by:
getContextPath in class RequestContext
Returns:
the context path all requests are rooted under
See Also:
HttpServletRequest.getContextPath()

getRequestPath

public java.lang.String getRequestPath()
Specified by:
getRequestPath in class RequestContext
Returns:
the path of the request

getUserPrincipal

public java.security.Principal getUserPrincipal()
Specified by:
getUserPrincipal in class RequestContext
Returns:
the security principal of the current user

sendRedirect

public void sendRedirect(java.lang.String path)
                  throws java.io.IOException
Send a redirect
Specified by:
sendRedirect in class RequestContext
Parameters:
path - the path to redirect
Throws:
java.io.IOException

setHeader

public void setHeader(java.lang.String name,
                      java.lang.String value)
Set a response header
Specified by:
setHeader in class RequestContext
Parameters:
name - the name
value - the value

executePath

protected void executePath(java.lang.String path,
                           boolean forward)
                    throws java.lang.Exception
Execute the path
Specified by:
executePath in class RequestContext
Parameters:
path - the web application page
forward - true to forward, false to include
Throws:
java.lang.Exception

Skip navigation links

Oracle® Fusion Middleware Site Studio for External Applications Java API Reference
11g Release 1 (11.1.1)

E17273-02


Copyright © 2010, 2011, Oracle and/or its affiliates. All rights reserved.