You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by co...@apache.org on 2001/02/27 07:59:15 UTC
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/core Container.java
costin 01/02/26 22:59:15
Modified: src/share/org/apache/tomcat/core Container.java
Log:
Added the shortcuts for getNote/setNote ( as in all other core objects that
support notes ) ( notes are similar with a Hashtable, but you can also
do indexed access - for better speed )
Revision Changes Path
1.48 +12 -0 jakarta-tomcat/src/share/org/apache/tomcat/core/Container.java
Index: Container.java
===================================================================
RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/Container.java,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -r1.47 -r1.48
--- Container.java 2001/02/20 03:17:56 1.47
+++ Container.java 2001/02/27 06:59:14 1.48
@@ -373,6 +373,18 @@
return notes[pos];
}
+ public Object getNote( String name ) throws TomcatException {
+ int id=contextM.getNoteId( ContextManager.CONTAINER_NOTE, name );
+ return getNote( id );
+ }
+
+ public void setNote( String name, Object value ) throws TomcatException {
+ int id=contextM.getNoteId( ContextManager.CONTAINER_NOTE, name );
+ setNote( id, value );
+ }
+
+
+
// -------------------- Interceptors --------------------
public static final int H_requestMap=0;
public static final int H_contextMap=1;