org.apache.empire.struts2.web.servlet
Class ServletContextWrapper

java.lang.Object
  extended by org.apache.empire.struts2.web.servlet.ServletContextWrapper
All Implemented Interfaces:
AppContext

public class ServletContextWrapper
extends Object
implements AppContext


Constructor Summary
ServletContextWrapper(javax.servlet.ServletContext ctx)
           
 
Method Summary
 Object getAttribute(String name)
           
 Enumeration<String> getAttributeNames()
           
 String getContextName()
           
 Object getExternalContext()
           
 String getInitParameter(String name)
           
 Enumeration<String> getInitParameterNames()
           
 String getMimeType(String file)
           
 String getRealPath(String path)
           
 URL getResource(String path)
           
 Set<String> getResourcePaths(String path)
           
 boolean isPortlet()
           
 void log(String msg)
           
 void log(String message, Throwable throwable)
           
 void removeAttribute(String name)
           
 void setAttribute(String name, Object object)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServletContextWrapper

public ServletContextWrapper(javax.servlet.ServletContext ctx)
Method Detail

getContextName

public String getContextName()
Specified by:
getContextName in interface AppContext

getExternalContext

public Object getExternalContext()
Specified by:
getExternalContext in interface AppContext

getMimeType

public String getMimeType(String file)
Specified by:
getMimeType in interface AppContext

isPortlet

public boolean isPortlet()
Specified by:
isPortlet in interface AppContext

getRealPath

public String getRealPath(String path)
Specified by:
getRealPath in interface AppContext

getResourcePaths

public Set<String> getResourcePaths(String path)
Specified by:
getResourcePaths in interface AppContext

getResource

public URL getResource(String path)
                throws MalformedURLException
Specified by:
getResource in interface AppContext
Throws:
MalformedURLException

log

public void log(String msg)
Specified by:
log in interface AppContext

log

public void log(String message,
                Throwable throwable)
Specified by:
log in interface AppContext

getInitParameterNames

public Enumeration<String> getInitParameterNames()
Specified by:
getInitParameterNames in interface AppContext

getInitParameter

public String getInitParameter(String name)
Specified by:
getInitParameter in interface AppContext

getAttributeNames

public Enumeration<String> getAttributeNames()
Specified by:
getAttributeNames in interface AppContext

getAttribute

public Object getAttribute(String name)
Specified by:
getAttribute in interface AppContext

removeAttribute

public void removeAttribute(String name)
Specified by:
removeAttribute in interface AppContext

setAttribute

public void setAttribute(String name,
                         Object object)
Specified by:
setAttribute in interface AppContext


Copyright © 2008-2012 Apache Software Foundation. All Rights Reserved.