org.apache.commons.jelly.tags.jetty
Class HttpContextTag

java.lang.Object
  |
  +--org.apache.commons.jelly.TagSupport
        |
        +--org.apache.commons.jelly.tags.jetty.HttpContextTag
All Implemented Interfaces:
org.apache.commons.jelly.Tag

public class HttpContextTag
extends org.apache.commons.jelly.TagSupport

Declare a context for a Jetty http server

Version:
$Id: HttpContextTag.java,v 1.3 2002/07/14 12:38:22 dion Exp $
Author:
rtl

Fields inherited from class org.apache.commons.jelly.TagSupport
body, context, hasTrimmed, parent, shouldTrim
 
Constructor Summary
HttpContextTag()
          Creates a new instance of HttpContextTag
 
Method Summary
 void addHandler(org.mortbay.http.HttpHandler httHandler)
          Add an http handler to the context instance
 void addSecurityConstraint(java.lang.String pathSpec, org.mortbay.http.SecurityConstraint sc)
          Add a security constraint for the specified path specification to the context instance
 void doTag(org.apache.commons.jelly.XMLOutput xmlOutput)
          Perform the tag functionality.
 java.lang.String getContextPath()
          Getter for property context path.
 java.lang.String getRealmName()
          Getter for property realm name.
 java.lang.String getResourceBase()
          Getter for property resourceBase.
 void setAuthenticator(org.mortbay.http.SecurityConstraint.Authenticator authenticator)
          Add an authenticator to the context instance
 void setContextPath(java.lang.String contextPath)
          Setter for property context path.
 void setRealmName(java.lang.String realmName)
          Setter for property context path.
 void setResourceBase(java.lang.String resourceBase)
          Setter for property resourceBase.
 
Methods inherited from class org.apache.commons.jelly.TagSupport
findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, getBody, getBodyText, getBodyText, getContext, getParent, invokeBody, isEscapeText, isTrim, setBody, setContext, setEscapeText, setParent, setTrim, trimBody
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HttpContextTag

public HttpContextTag()
Creates a new instance of HttpContextTag
Method Detail

doTag

public void doTag(org.apache.commons.jelly.XMLOutput xmlOutput)
           throws org.apache.commons.jelly.JellyTagException
Perform the tag functionality. In this case, setup the context path and resource base before adding the context to the parent server
Overrides:
doTag in class org.apache.commons.jelly.TagSupport
Parameters:
xmlOutput - where to send output
Throws:
java.lang.Exception - when an error occurs

addHandler

public void addHandler(org.mortbay.http.HttpHandler httHandler)
Add an http handler to the context instance
Parameters:
handler - the handler to add

addSecurityConstraint

public void addSecurityConstraint(java.lang.String pathSpec,
                                  org.mortbay.http.SecurityConstraint sc)
Add a security constraint for the specified path specification to the context instance
Parameters:
pathSpec - the path specification for the security constraint
sc - the security constraint to add

setAuthenticator

public void setAuthenticator(org.mortbay.http.SecurityConstraint.Authenticator authenticator)
Add an authenticator to the context instance
Parameters:
authenticator - the authenticator to add

getContextPath

public java.lang.String getContextPath()
Getter for property context path.
Returns:
value of property context path.

setContextPath

public void setContextPath(java.lang.String contextPath)
Setter for property context path.
Parameters:
path - New resourceBase of property context path.

getResourceBase

public java.lang.String getResourceBase()
Getter for property resourceBase.
Returns:
value of property resourceBase.

setResourceBase

public void setResourceBase(java.lang.String resourceBase)
Setter for property resourceBase.
Parameters:
resourceBase - New value of property resourceBase.

getRealmName

public java.lang.String getRealmName()
Getter for property realm name.
Returns:
value of property realm name.

setRealmName

public void setRealmName(java.lang.String realmName)
Setter for property context path.
Parameters:
path - New resourceBase of property context path.


Copyright © 2002-2004 Apache Software Foundation. All Rights Reserved.