Methods Summary |
---|
public void | addHandlerCallback(org.apache.jk.core.JkHandler w)Experimental, will be replaced. This allows handlers to be
notified when other handlers are added.
|
public MsgContext | createMsgContext()
return new MsgContext(8*1024);
|
public MsgContext | createMsgContext(int bsize)
return new MsgContext(bsize);
|
public void | destroy()Clean up and stop the handler
|
public java.lang.String | getDomain()
return domain;
|
public int | getId()
return id;
|
public java.lang.String | getName()
return name;
|
public java.lang.String | getNext()
if( nextName==null ) {
if( next!=null)
nextName=next.getName();
}
return nextName;
|
public javax.management.ObjectName | getObjectName()
return oname;
|
public java.lang.String | getProperty(java.lang.String name)
return properties.getProperty(name) ;
|
public void | handleNotification(javax.management.Notification notification, java.lang.Object handback)
// BaseNotification bNot=(BaseNotification)notification;
// int code=bNot.getCode();
//
// MsgContext ctx=(MsgContext)bNot.getSource();
|
public void | init()Should register the request types it can handle,
same style as apache2.
|
public int | invoke(Msg msg, MsgContext mc)
return OK;
|
public void | pause()
|
public void | postDeregister()
|
public void | postRegister(java.lang.Boolean registrationDone)
|
public void | preDeregister()
|
public javax.management.ObjectName | preRegister(javax.management.MBeanServer server, javax.management.ObjectName oname)
this.oname=oname;
mserver=server;
domain=oname.getDomain();
if( name==null ) {
name=oname.getKeyProperty("name");
}
// we need to create a workerEnv or set one.
ObjectName wEnvName=new ObjectName(domain + ":type=JkWorkerEnv");
if ( wEnv == null ) {
wEnv=new WorkerEnv();
}
if( ! mserver.isRegistered(wEnvName )) {
Registry.getRegistry(null, null).registerComponent(wEnv, wEnvName, null);
}
mserver.invoke( wEnvName, "addHandler",
new Object[] {name, this},
new String[] {"java.lang.String",
"org.apache.jk.core.JkHandler"});
return oname;
|
public void | resume()
|
public void | setId(int id)Set the id of the worker. We use an id for faster dispatch.
Since we expect a decent number of handler in system, the
id is unique - that means we may have to allocate bigger
dispatch tables. ( easy to fix if needed )
this.id=id;
|
public void | setName(java.lang.String s)Set the name of the handler. Will allways be called by
worker env after creating the worker.
name=s;
|
public void | setNext(org.apache.jk.core.JkHandler h)Catalina-style "recursive" invocation.
A chain is used for Apache/3.3 style iterative invocation.
next=h;
|
public void | setNext(java.lang.String s)
nextName=s;
|
public void | setProperty(java.lang.String name, java.lang.String value)
properties.put( name, value );
|
public void | setWorkerEnv(WorkerEnv we)
this.wEnv=we;
|