Methods Summary |
---|
public void | addHandler(java.lang.String name, JkHandler w)
JkHandler oldH = getHandler(name);
if(oldH == w) {
// Already added
return;
}
w.setWorkerEnv( this );
w.setName( name );
handlersMap.put( name, w );
if( handlerCount > handlersTable.length ) {
JkHandler newT[]=new JkHandler[ 2 * handlersTable.length ];
System.arraycopy( handlersTable, 0, newT, 0, handlersTable.length );
handlersTable=newT;
}
if(oldH == null) {
handlersTable[handlerCount]=w;
w.setId( handlerCount );
handlerCount++;
} else {
handlersTable[oldH.getId()]=w;
w.setId(oldH.getId());
}
// Notify all other handlers of the new one
// XXX Could be a Coyote action ?
for( int i=0; i< handlerCount ; i++ ) {
handlersTable[i].addHandlerCallback( w );
}
|
public final JkHandler | getHandler(java.lang.String name)
return (JkHandler)handlersMap.get(name);
|
public final JkHandler | getHandler(int id)
return handlersTable[id];
|
public final int | getHandlerCount()
return handlerCount;
|
public javax.management.ObjectName[] | getHandlersObjectName()
ObjectName onames[]=new ObjectName[ handlerCount ];
for( int i=0; i<handlerCount; i++ ) {
onames[i]=handlersTable[i].getObjectName();
}
return onames;
|
public java.lang.String | getJkHome()
return home;
|
public int | getLocalId()
return localId;
|
public final java.lang.Object | getNote(int i)
return notes[i];
|
public int | getNoteId(int type, java.lang.String name)
for( int i=0; i<noteId[type]; i++ ) {
if( name.equals( noteName[type][i] ))
return i;
}
int id=noteId[type]++;
noteName[type][id]=name;
return id;
|
public void | setJkHome(java.lang.String s)
home=s;
|
public void | setLocalId(int id)
localId=id;
|
public final void | setNote(int i, java.lang.Object o)
notes[i]=o;
|