org.apache.shiro.web.servlet
Class ServletContextSupport

java.lang.Object
  extended by org.apache.shiro.web.servlet.ServletContextSupport
Direct Known Subclasses:
AbstractFilter

public class ServletContextSupport
extends Object

Base implementation for any components that need to access the web application's ServletContext.

Since:
0.2

Constructor Summary
ServletContextSupport()
           
 
Method Summary
protected  Object getContextAttribute(String key)
           
protected  String getContextInitParam(String paramName)
           
 ServletContext getServletContext()
           
protected  void removeContextAttribute(String key)
           
protected  void setContextAttribute(String key, Object value)
           
 void setServletContext(ServletContext servletContext)
           
 String toString()
          It is highly recommended not to override this method directly, and instead override the toStringBuilder() method, a better-performing alternative.
protected  StringBuilder toStringBuilder()
          Same concept as toString(), but returns a StringBuilder instance instead.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ServletContextSupport

public ServletContextSupport()
Method Detail

getServletContext

public ServletContext getServletContext()

setServletContext

public void setServletContext(ServletContext servletContext)

getContextInitParam

protected String getContextInitParam(String paramName)

setContextAttribute

protected void setContextAttribute(String key,
                                   Object value)

getContextAttribute

protected Object getContextAttribute(String key)

removeContextAttribute

protected void removeContextAttribute(String key)

toString

public String toString()
It is highly recommended not to override this method directly, and instead override the toStringBuilder() method, a better-performing alternative.

Overrides:
toString in class Object
Returns:
the String representation of this instance.

toStringBuilder

protected StringBuilder toStringBuilder()
Same concept as toString(), but returns a StringBuilder instance instead.

Returns:
a StringBuilder instance to use for appending String data that will eventually be returned from a toString() invocation.


Copyright © 2004-2014 The Apache Software Foundation. All Rights Reserved.