diff --git a/java/server/src/org/openqa/jetty/html/Applet.java b/java/server/src/org/openqa/jetty/html/Applet.java index 348482da8412e..8048fde5023cd 100644 --- a/java/server/src/org/openqa/jetty/html/Applet.java +++ b/java/server/src/org/openqa/jetty/html/Applet.java @@ -84,6 +84,7 @@ public Applet setDebug(boolean debug){ * @param alt The alternate element to display * @deprecated use add */ + @Deprecated public Applet setAlternate(Element alt) { add(alt); @@ -95,6 +96,7 @@ public Applet setAlternate(Element alt) * @param alt The alternate element to display * @deprecated use add */ + @Deprecated public Applet setAlternate(String alt) { add(alt); diff --git a/java/server/src/org/openqa/jetty/html/Element.java b/java/server/src/org/openqa/jetty/html/Element.java index f82c392989888..d49f87a60e70b 100644 --- a/java/server/src/org/openqa/jetty/html/Element.java +++ b/java/server/src/org/openqa/jetty/html/Element.java @@ -172,6 +172,7 @@ public String attributes() * @param attributes String of HTML attributes to add to the element. * @return This Element so calls can be chained. */ + @Deprecated public Element attributes(String attributes) { if (log.isDebugEnabled() && attributes!=null && attributes.indexOf('=')>=0) diff --git a/java/server/src/org/openqa/jetty/html/Table.java b/java/server/src/org/openqa/jetty/html/Table.java index 914331462c9f9..4be79ae47bcdd 100644 --- a/java/server/src/org/openqa/jetty/html/Table.java +++ b/java/server/src/org/openqa/jetty/html/Table.java @@ -287,6 +287,7 @@ public Block cell() * threads factory. * @deprecated Use setNestingFactory or setThreadNestingFactory */ + @Deprecated public static void setCellNestingFactory(CompositeFactory factory) { if (threadNestingMap==null) diff --git a/java/server/src/org/openqa/jetty/html/Text.java b/java/server/src/org/openqa/jetty/html/Text.java index 510d8a263f03c..ae99138bcc940 100644 --- a/java/server/src/org/openqa/jetty/html/Text.java +++ b/java/server/src/org/openqa/jetty/html/Text.java @@ -20,6 +20,7 @@ /** A simple block of straight text. * @deprecated all Composites now take Strings direct. */ +@Deprecated public class Text extends Composite { /* ----------------------------------------------------------------- */ diff --git a/java/server/src/org/openqa/jetty/http/HttpRequest.java b/java/server/src/org/openqa/jetty/http/HttpRequest.java index 9678bfa32f58e..003dee7ade5f0 100644 --- a/java/server/src/org/openqa/jetty/http/HttpRequest.java +++ b/java/server/src/org/openqa/jetty/http/HttpRequest.java @@ -177,6 +177,7 @@ public void setTimeStamp(long ts) /** * @deprecated use getHttpResponse() */ + @Deprecated public HttpResponse getResponse() { return getHttpResponse(); diff --git a/java/server/src/org/openqa/jetty/http/HttpResponse.java b/java/server/src/org/openqa/jetty/http/HttpResponse.java index fb8225883923e..973d20a483da0 100644 --- a/java/server/src/org/openqa/jetty/http/HttpResponse.java +++ b/java/server/src/org/openqa/jetty/http/HttpResponse.java @@ -229,6 +229,7 @@ public void reset() /** * @deprecated use getHttpRequest() */ + @Deprecated public HttpRequest getRequest() { return getHttpRequest(); diff --git a/java/server/src/org/openqa/jetty/http/HttpServer.java b/java/server/src/org/openqa/jetty/http/HttpServer.java index 233b3cc1681e1..007ee8bf944ee 100644 --- a/java/server/src/org/openqa/jetty/http/HttpServer.java +++ b/java/server/src/org/openqa/jetty/http/HttpServer.java @@ -98,6 +98,7 @@ public static Collection getHttpServers() /** * @deprecated User getHttpServers() */ + @Deprecated public static List getHttpServerList() { return new ArrayList(__roServers); @@ -639,6 +640,7 @@ public void setRequestsPerGC(int requestsPerGC) * @param classes * @deprecated Use HttpContext */ + @Deprecated public void setSystemClasses(String[] classes) { _systemClasses=classes; @@ -649,6 +651,7 @@ public void setSystemClasses(String[] classes) * @return A String array with a list of system classes for this instance. * @deprecated Use HttpContext */ + @Deprecated public String[] getSystemClasses() { return _systemClasses; @@ -659,6 +662,7 @@ public String[] getSystemClasses() * @param classes * @deprecated Use HttpContext */ + @Deprecated public void setServerClasses(String[] classes) { _serverClasses=classes; @@ -670,6 +674,7 @@ public void setServerClasses(String[] classes) * @see #setServerClasses(java.lang.String[]) * @deprecated Use HttpContext */ + @Deprecated public String[] getServerClasses() { return _serverClasses; @@ -814,6 +819,7 @@ public void join() * @param virtualHost Host name or IP * @param alias Alias hostname or IP */ + @Deprecated public void addHostAlias(String virtualHost, String alias) { log.warn("addHostAlias is deprecated. Use HttpContext.addVirtualHost"); diff --git a/java/server/src/org/openqa/jetty/http/JsseListener.java b/java/server/src/org/openqa/jetty/http/JsseListener.java index ffe3414a5cdd5..a81df1a04fadb 100644 --- a/java/server/src/org/openqa/jetty/http/JsseListener.java +++ b/java/server/src/org/openqa/jetty/http/JsseListener.java @@ -54,6 +54,7 @@ * @author Forge Research Pty Ltd ACN 003 491 576 * @author Jan Hlavatý */ +@Deprecated public abstract class JsseListener extends SocketListener { private static Log log = LogFactory.getLog(JsseListener.class); diff --git a/java/server/src/org/openqa/jetty/http/NCSARequestLog.java b/java/server/src/org/openqa/jetty/http/NCSARequestLog.java index 4ab1b0b3d1ec1..1a84f4b5fb118 100644 --- a/java/server/src/org/openqa/jetty/http/NCSARequestLog.java +++ b/java/server/src/org/openqa/jetty/http/NCSARequestLog.java @@ -225,6 +225,7 @@ public void setAppend(boolean a) /** * @deprecated ignored */ + @Deprecated public void setBuffered(boolean b) {} diff --git a/java/server/src/org/openqa/jetty/http/SunJsseListener.java b/java/server/src/org/openqa/jetty/http/SunJsseListener.java index 8f49eb679dbce..23caa029c8794 100644 --- a/java/server/src/org/openqa/jetty/http/SunJsseListener.java +++ b/java/server/src/org/openqa/jetty/http/SunJsseListener.java @@ -50,6 +50,7 @@ * @author Court Demas (court@kiwiconsulting.com) * @author Forge Research Pty Ltd ACN 003 491 576 **/ +@Deprecated public class SunJsseListener extends JsseListener { private static Log log = LogFactory.getLog(SunJsseListener.class); diff --git a/java/server/src/org/openqa/jetty/jetty/servlet/AbstractSessionManager.java b/java/server/src/org/openqa/jetty/jetty/servlet/AbstractSessionManager.java index 4e8a3716b24da..82cbd188aefa5 100644 --- a/java/server/src/org/openqa/jetty/jetty/servlet/AbstractSessionManager.java +++ b/java/server/src/org/openqa/jetty/jetty/servlet/AbstractSessionManager.java @@ -116,6 +116,7 @@ public AbstractSessionManager(Random random) * @deprecated use getCrossContextSessionIDs * session IDs */ + @Deprecated public boolean getUseRequestedId() { return _crossContextSessionIDs; @@ -127,6 +128,7 @@ public boolean getUseRequestedId() * @deprecated use setCrossContextSessionIDs * session IDs */ + @Deprecated public void setUseRequestedId(boolean useRequestedId) { _crossContextSessionIDs = useRequestedId; @@ -716,6 +718,7 @@ public int getMaxInactiveInterval() /** * @deprecated */ + @Deprecated public HttpSessionContext getSessionContext() throws IllegalStateException { @@ -892,6 +895,7 @@ public synchronized void removeAttribute(String name) * @deprecated As of Version 2.2, this method is * replaced by {@link #getAttribute} */ + @Deprecated public Object getValue(String name) throws IllegalStateException { @@ -903,6 +907,7 @@ public Object getValue(String name) * @deprecated As of Version 2.2, this method is * replaced by {@link #getAttributeNames} */ + @Deprecated public synchronized String[] getValueNames() throws IllegalStateException { @@ -918,6 +923,7 @@ public synchronized String[] getValueNames() * @deprecated As of Version 2.2, this method is * replaced by {@link #setAttribute} */ + @Deprecated public void putValue(java.lang.String name, java.lang.Object value) throws IllegalStateException @@ -930,6 +936,7 @@ public void putValue(java.lang.String name, * @deprecated As of Version 2.2, this method is * replaced by {@link #removeAttribute} */ + @Deprecated public void removeValue(java.lang.String name) throws IllegalStateException { diff --git a/java/server/src/org/openqa/jetty/jetty/servlet/Dispatcher.java b/java/server/src/org/openqa/jetty/jetty/servlet/Dispatcher.java index b106973c2aa2c..d727967496803 100644 --- a/java/server/src/org/openqa/jetty/jetty/servlet/Dispatcher.java +++ b/java/server/src/org/openqa/jetty/jetty/servlet/Dispatcher.java @@ -931,6 +931,7 @@ public void setStatus(int status) * @param status the status code * @param message the status message */ + @Deprecated public void setStatus(int status, String message) { if (_request._filterType!=Dispatcher.__ERROR && !_include) diff --git a/java/server/src/org/openqa/jetty/jetty/servlet/ServletHandler.java b/java/server/src/org/openqa/jetty/jetty/servlet/ServletHandler.java index 6c15335e8d10f..4e6243cf1cccf 100644 --- a/java/server/src/org/openqa/jetty/jetty/servlet/ServletHandler.java +++ b/java/server/src/org/openqa/jetty/jetty/servlet/ServletHandler.java @@ -221,6 +221,7 @@ public SessionManager getSessionManager() /** Set the dynamic servlet path. * @deprecated Use org.openqa.jetty.jetty.servlet.Invoker */ + @Deprecated public void setDynamicServletPathSpec(String dynamicServletPathSpec) { log.warn("setDynamicServletPathSpec is Deprecated."); @@ -230,6 +231,7 @@ public void setDynamicServletPathSpec(String dynamicServletPathSpec) /** Set dynamic servlet initial parameters. * @deprecated Use org.openqa.jetty.jetty.servlet.Invoker */ + @Deprecated public void setDynamicInitParams(Map initParams) { log.warn("setDynamicInitParams is Deprecated."); @@ -239,6 +241,7 @@ public void setDynamicInitParams(Map initParams) /** Set serving dynamic system servlets. * @deprecated Use org.openqa.jetty.jetty.servlet.Invoker */ + @Deprecated public void setServeDynamicSystemServlets(boolean b) { log.warn("setServeDynamicSystemServlets is Deprecated."); @@ -1114,6 +1117,7 @@ public RequestDispatcher getNamedDispatcher(String name) /** * @deprecated */ + @Deprecated public Servlet getServlet(String name) { return null; @@ -1123,6 +1127,7 @@ public Servlet getServlet(String name) /** * @deprecated */ + @Deprecated public Enumeration getServlets() { return Collections.enumeration(Collections.EMPTY_LIST); @@ -1132,6 +1137,7 @@ public Enumeration getServlets() /** * @deprecated */ + @Deprecated public Enumeration getServletNames() { return Collections.enumeration(Collections.EMPTY_LIST); @@ -1155,6 +1161,7 @@ public void log(String msg) * {@link #log(String message, Throwable throwable)} * instead. */ + @Deprecated public void log(Exception e, String msg) { _contextLog.warn(msg,e); diff --git a/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpRequest.java b/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpRequest.java index b4d2798ae1db3..5b6739fd00c4f 100644 --- a/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpRequest.java +++ b/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpRequest.java @@ -565,6 +565,7 @@ public boolean isRequestedSessionIdFromURL() /** * @deprecated */ + @Deprecated public boolean isRequestedSessionIdFromUrl() { return isRequestedSessionIdFromURL(); @@ -770,6 +771,7 @@ public String getRemoteHost() * @deprecated As of Version 2.1 of the Java Servlet API, * use {@link javax.servlet.ServletContext#getRealPath} instead. */ + @Deprecated public String getRealPath(String path) { return _servletHandler.getServletContext().getRealPath(path); diff --git a/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpResponse.java b/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpResponse.java index fede9d4a2951c..de9c37ba8243f 100644 --- a/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpResponse.java +++ b/java/server/src/org/openqa/jetty/jetty/servlet/ServletHttpResponse.java @@ -352,7 +352,8 @@ public String encodeRedirectURL(String url) /** * @deprecated As of version 2.1, use encodeURL(String url) instead */ - public String encodeUrl(String url) + @Deprecated + public String encodeUrl(String url) { return encodeURL(url); } @@ -362,7 +363,8 @@ public String encodeUrl(String url) * @deprecated As of version 2.1, use * encodeRedirectURL(String url) instead */ - public String encodeRedirectUrl(String url) + @Deprecated + public String encodeRedirectUrl(String url) { return encodeRedirectURL(url); } @@ -527,7 +529,8 @@ public void setStatus(int status) * @param status the status code * @param message the status message */ - public void setStatus(int status, String message) + @Deprecated + public void setStatus(int status, String message) { setStatus(status); _httpResponse.setReason(message); diff --git a/java/server/src/org/openqa/jetty/jetty/servlet/SessionContext.java b/java/server/src/org/openqa/jetty/jetty/servlet/SessionContext.java index 77c58a3a275fe..474449513a882 100644 --- a/java/server/src/org/openqa/jetty/jetty/servlet/SessionContext.java +++ b/java/server/src/org/openqa/jetty/jetty/servlet/SessionContext.java @@ -38,6 +38,7 @@ private SessionContext(){} /** * @deprecated From HttpSessionContext */ + @Deprecated public Enumeration getIds() { return Collections.enumeration(Collections.EMPTY_LIST); @@ -47,6 +48,7 @@ public Enumeration getIds() /** * @deprecated From HttpSessionContext */ + @Deprecated public HttpSession getSession(String id) { return null; diff --git a/java/server/src/org/openqa/jetty/log/OutputStreamLogSink.java b/java/server/src/org/openqa/jetty/log/OutputStreamLogSink.java index 999243ecb6793..167587c957fae 100644 --- a/java/server/src/org/openqa/jetty/log/OutputStreamLogSink.java +++ b/java/server/src/org/openqa/jetty/log/OutputStreamLogSink.java @@ -117,6 +117,7 @@ public void setLogDateFormat(String logDateFormat) /** * @deprecated Use getLogTimeZone() */ + @Deprecated public String getLogTimezone() { return _logTimezone; @@ -126,6 +127,7 @@ public String getLogTimezone() /** * @deprecated Use setLogTimeZone(String) */ + @Deprecated public void setLogTimezone(String logTimezone) { _logTimezone=logTimezone; diff --git a/java/server/src/org/openqa/jetty/util/LazyList.java b/java/server/src/org/openqa/jetty/util/LazyList.java index f5cd93dbd3d78..e95dbf21a4128 100644 --- a/java/server/src/org/openqa/jetty/util/LazyList.java +++ b/java/server/src/org/openqa/jetty/util/LazyList.java @@ -128,6 +128,7 @@ public static Object add(Object list, int index, Object item) * @return The lazylist created or added to. * @deprecated Use addCollection */ + @Deprecated protected Object add(Object list, Collection collection) { Iterator i=collection.iterator(); diff --git a/java/server/src/org/openqa/jetty/util/Primitive.java b/java/server/src/org/openqa/jetty/util/Primitive.java index 870f3153769a7..b00fa83893c74 100644 --- a/java/server/src/org/openqa/jetty/util/Primitive.java +++ b/java/server/src/org/openqa/jetty/util/Primitive.java @@ -24,6 +24,7 @@ * @author Greg Wilkins (gregw) * @deprecated Use TypeUtil */ +@Deprecated public class Primitive extends TypeUtil { } diff --git a/java/server/src/org/openqa/jetty/util/ThreadPool.java b/java/server/src/org/openqa/jetty/util/ThreadPool.java index c0210acb798e6..1ec008ddecc06 100644 --- a/java/server/src/org/openqa/jetty/util/ThreadPool.java +++ b/java/server/src/org/openqa/jetty/util/ThreadPool.java @@ -120,6 +120,7 @@ else if (!name.equals(getName())) /** * @deprecated use getName() */ + @Deprecated public String getPoolName() { return getName(); @@ -129,6 +130,7 @@ public String getPoolName() /** * @deprecated use setName(String) */ + @Deprecated public void setPoolName(String name) { setName(name); @@ -294,6 +296,7 @@ public void setThreadsPriority(int priority) * * @deprecated maxIdleTime is used instead. */ + @Deprecated public void setMaxStopTimeMs(int ms) { log.warn("setMaxStopTimeMs is deprecated. No longer required."); diff --git a/java/server/src/org/openqa/jetty/util/ThreadedServer.java b/java/server/src/org/openqa/jetty/util/ThreadedServer.java index 9f3bd4fffdb20..e780fe76cd6ec 100644 --- a/java/server/src/org/openqa/jetty/util/ThreadedServer.java +++ b/java/server/src/org/openqa/jetty/util/ThreadedServer.java @@ -4,7 +4,7 @@ // ------------------------------------------------------------------------ // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. -// You may obtain a copy of the License at +// You may obtain a copy of the License at // http://www.apache.org/licenses/LICENSE-2.0 // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, @@ -37,7 +37,7 @@ * The properties THREADED_SERVER_MIN_THREADS and THREADED_SERVER_MAX_THREADS can be set to control * the number of threads created. *

- * + * * @version $Id: ThreadedServer.java,v 1.41 2005/12/10 00:38:20 gregwilkins Exp $ * @author Greg Wilkins */ @@ -113,7 +113,7 @@ public ThreadedServer(InetAddrPort address) /* ------------------------------------------------------------ */ /** * Set the server InetAddress and port. - * + * * @param address The Address to listen on, or 0.0.0.0:port for all interfaces. */ public synchronized void setInetAddrPort(InetAddrPort address) @@ -218,9 +218,10 @@ public int getPort() /* ------------------------------------------------------------ */ /** * Set Max Read Time. - * + * * @deprecated maxIdleTime is used instead. */ + @Deprecated public void setMaxReadTimeMs(int ms) { log.warn("setMaxReadTimeMs is deprecated. Use setMaxIdleTimeMs()"); @@ -284,7 +285,7 @@ public int getAcceptQueueSize() /** * The size of the queue for unaccepted connections. If not set, will default to greater of * maxThreads or 50. - * + * * @param acceptQueueSize The acceptQueueSize to set. */ public void setAcceptQueueSize(int acceptQueueSize) @@ -345,7 +346,7 @@ protected void handleConnection(Socket connection) throws IOException /* ------------------------------------------------------------ */ /** * Handle Job. Implementation of ThreadPool.handle(), calls handleConnection. - * + * * @param job A Connection. */ public void handle(Object job) @@ -377,7 +378,7 @@ public void handle(Object job) /** * New server socket. Creates a new servers socket. May be overriden by derived class to create * specialist serversockets (eg SSL). - * + * * @param address Address and port * @param acceptQueueSize Accept queue size * @return The new ServerSocket @@ -395,22 +396,23 @@ protected ServerSocket newServerSocket(InetAddrPort address, int acceptQueueSize /** * Accept socket connection. May be overriden by derived class to create specialist * serversockets (eg SSL). - * + * * @deprecated use acceptSocket(int timeout) * @param ignored * @param timeout The time to wait for a connection. Normally passed the ThreadPool maxIdleTime. * @return Accepted Socket */ + @Deprecated protected Socket acceptSocket(ServerSocket ignored, int timeout) { return acceptSocket(timeout); } - + /* ------------------------------------------------------------ */ /** * Accept socket connection. May be overridden by derived class to create specialist * serversockets (eg SSL). - * + * * @param timeout The time to wait for a connection. Normally passed the ThreadPool maxIdleTime. * @return Accepted Socket */ @@ -466,7 +468,7 @@ protected Socket acceptSocket(int timeout) /** * Open the server socket. This method can be called to open the server socket in advance of * starting the listener. This can be used to test if the port is available. - * + * * @exception IOException if an error occurs */ public void open() throws IOException @@ -544,7 +546,7 @@ public void stop() throws InterruptedException for (int a = 0; _acceptor!=null && a<_acceptor.length; a++) { Acceptor acc = _acceptor[a]; - if (acc != null) + if (acc != null) acc.interrupt(); } Thread.sleep(100); @@ -583,7 +585,7 @@ public void stop() throws InterruptedException /* ------------------------------------------------------------ */ /** * Kill a job. This method closes IDLE and socket associated with a job - * + * * @param thread * @param job */ @@ -631,7 +633,7 @@ public void run() { // Accept a socket Socket socket = acceptSocket(_soTimeOut); - + // Handle the socket if (socket != null) { @@ -661,7 +663,7 @@ public void run() if (_acceptor != null) { for (int a = 0; a < _acceptor.length; a++) - if (_acceptor[a] == this) + if (_acceptor[a] == this) _acceptor[a] = null; } threadedServer.notifyAll();