FileDocCategorySizeDatePackage
SessionsTask.javaAPI DocApache Tomcat 6.0.142175Fri Jul 20 04:20:32 BST 2007org.apache.catalina.ant

SessionsTask

public class SessionsTask extends AbstractCatalinaTask
Ant task that implements the /sessions command supported by the Tomcat manager application.
author
Vivek Chopra
version
$Revision: 467222 $

Fields Summary
protected String
path
The context path of the web application we are managing.
Constructors Summary
Methods Summary
public voidexecute()
Execute the requested operation.

exception
BuildException if an error occurs


        super.execute();
        if (path == null) {
            throw new BuildException
                ("Must specify 'path' attribute");
        }
        
        try {
            execute("/sessions?path=" + URLEncoder.encode(this.path, getCharset()));
        } catch (UnsupportedEncodingException e) {
            throw new BuildException
                ("Invalid 'charset' attribute: " + getCharset());
        }
        
    
public java.lang.StringgetPath()


       
        return (this.path);
    
public voidsetPath(java.lang.String path)

        this.path = path;