http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/blob/b852a3e8/content/site/apidocs/src-html/org/apache/juneau/rest/RequestQuery.html ---------------------------------------------------------------------- diff --git a/content/site/apidocs/src-html/org/apache/juneau/rest/RequestQuery.html b/content/site/apidocs/src-html/org/apache/juneau/rest/RequestQuery.html index ab8f6bd..37ba0f1 100644 --- a/content/site/apidocs/src-html/org/apache/juneau/rest/RequestQuery.html +++ b/content/site/apidocs/src-html/org/apache/juneau/rest/RequestQuery.html @@ -63,7 +63,7 @@ <span class="sourceLineNo">055</span> for (Map.Entry<String,String> e : defaultEntries.entrySet()) {<a name="line.55"></a> <span class="sourceLineNo">056</span> String key = e.getKey(), value = e.getValue();<a name="line.56"></a> <span class="sourceLineNo">057</span> String[] v = get(key);<a name="line.57"></a> -<span class="sourceLineNo">058</span> if (v == null)<a name="line.58"></a> +<span class="sourceLineNo">058</span> if (v == null || v.length == 0 || StringUtils.isEmpty(v[0]))<a name="line.58"></a> <span class="sourceLineNo">059</span> put(key, new String[]{value});<a name="line.59"></a> <span class="sourceLineNo">060</span> }<a name="line.60"></a> <span class="sourceLineNo">061</span> }<a name="line.61"></a> @@ -94,13 +94,13 @@ <span class="sourceLineNo">086</span> String[] v = get(name);<a name="line.86"></a> <span class="sourceLineNo">087</span> if (v == null || v.length == 0)<a name="line.87"></a> <span class="sourceLineNo">088</span> return null;<a name="line.88"></a> -<span class="sourceLineNo">089</span> if (v.length == 1 && v[0] != null && v[0].isEmpty()) {<a name="line.89"></a> -<span class="sourceLineNo">090</span> // Fix for behavior difference between Tomcat and WAS.<a name="line.90"></a> -<span class="sourceLineNo">091</span> // getParameter("foo") on "&foo" in Tomcat returns "".<a name="line.91"></a> -<span class="sourceLineNo">092</span> // getParameter("foo") on "&foo" in WAS returns null.<a name="line.92"></a> -<span class="sourceLineNo">093</span> if (containsKey(name))<a name="line.93"></a> -<span class="sourceLineNo">094</span> return null;<a name="line.94"></a> -<span class="sourceLineNo">095</span> }<a name="line.95"></a> +<span class="sourceLineNo">089</span><a name="line.89"></a> +<span class="sourceLineNo">090</span> // Fix for behavior difference between Tomcat and WAS.<a name="line.90"></a> +<span class="sourceLineNo">091</span> // getParameter("foo") on "&foo" in Tomcat returns "".<a name="line.91"></a> +<span class="sourceLineNo">092</span> // getParameter("foo") on "&foo" in WAS returns null.<a name="line.92"></a> +<span class="sourceLineNo">093</span> if (v.length == 1 && v[0] == null) <a name="line.93"></a> +<span class="sourceLineNo">094</span> return "";<a name="line.94"></a> +<span class="sourceLineNo">095</span><a name="line.95"></a> <span class="sourceLineNo">096</span> return v[0];<a name="line.96"></a> <span class="sourceLineNo">097</span> }<a name="line.97"></a> <span class="sourceLineNo">098</span><a name="line.98"></a> @@ -113,7 +113,7 @@ <span class="sourceLineNo">105</span> */<a name="line.105"></a> <span class="sourceLineNo">106</span> public String getFirst(String name, String def) {<a name="line.106"></a> <span class="sourceLineNo">107</span> String s = getFirst(name);<a name="line.107"></a> -<span class="sourceLineNo">108</span> return s == null ? def : s;<a name="line.108"></a> +<span class="sourceLineNo">108</span> return StringUtils.isEmpty(s) ? def : s;<a name="line.108"></a> <span class="sourceLineNo">109</span> }<a name="line.109"></a> <span class="sourceLineNo">110</span><a name="line.110"></a> <span class="sourceLineNo">111</span> /**<a name="line.111"></a>
http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/blob/b852a3e8/content/site/apidocs/src-html/org/apache/juneau/rest/RestContext.html ---------------------------------------------------------------------- diff --git a/content/site/apidocs/src-html/org/apache/juneau/rest/RestContext.html b/content/site/apidocs/src-html/org/apache/juneau/rest/RestContext.html index 3a1aa5e..7fb6fd2 100644 --- a/content/site/apidocs/src-html/org/apache/juneau/rest/RestContext.html +++ b/content/site/apidocs/src-html/org/apache/juneau/rest/RestContext.html @@ -207,7 +207,7 @@ <span class="sourceLineNo">199</span> /**<a name="line.199"></a> <span class="sourceLineNo">200</span> * The request servlet path.<a name="line.200"></a> <span class="sourceLineNo">201</span> * <p><a name="line.201"></a> -<span class="sourceLineNo">202</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.202"></a> +<span class="sourceLineNo">202</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.202"></a> <span class="sourceLineNo">203</span> * <p><a name="line.203"></a> <span class="sourceLineNo">204</span> * Equivalent to the value returned by {@link RestRequest#getServletPath()}<a name="line.204"></a> <span class="sourceLineNo">205</span> */<a name="line.205"></a> @@ -230,7 +230,7 @@ <span class="sourceLineNo">222</span> /**<a name="line.222"></a> <span class="sourceLineNo">223</span> * The request URI path info.<a name="line.223"></a> <span class="sourceLineNo">224</span> * <p><a name="line.224"></a> -<span class="sourceLineNo">225</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.225"></a> +<span class="sourceLineNo">225</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.225"></a> <span class="sourceLineNo">226</span> * <p><a name="line.226"></a> <span class="sourceLineNo">227</span> * Equivalent to the value returned by {@link RestRequest#getPathInfo()}<a name="line.227"></a> <span class="sourceLineNo">228</span> */<a name="line.228"></a> @@ -239,7 +239,7 @@ <span class="sourceLineNo">231</span> /**<a name="line.231"></a> <span class="sourceLineNo">232</span> * The request URI.<a name="line.232"></a> <span class="sourceLineNo">233</span> * <p><a name="line.233"></a> -<span class="sourceLineNo">234</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.234"></a> +<span class="sourceLineNo">234</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.234"></a> <span class="sourceLineNo">235</span> * <p><a name="line.235"></a> <span class="sourceLineNo">236</span> * Equivalent to the value returned by {@link RestRequest#getRequestURI()}<a name="line.236"></a> <span class="sourceLineNo">237</span> */<a name="line.237"></a> @@ -248,7 +248,7 @@ <span class="sourceLineNo">240</span> /**<a name="line.240"></a> <span class="sourceLineNo">241</span> * The request method.<a name="line.241"></a> <span class="sourceLineNo">242</span> * <p><a name="line.242"></a> -<span class="sourceLineNo">243</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.243"></a> +<span class="sourceLineNo">243</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.243"></a> <span class="sourceLineNo">244</span> * <p><a name="line.244"></a> <span class="sourceLineNo">245</span> * Equivalent to the value returned by {@link RestRequest#getMethod()}<a name="line.245"></a> <span class="sourceLineNo">246</span> */<a name="line.246"></a> @@ -257,7 +257,7 @@ <span class="sourceLineNo">249</span> /**<a name="line.249"></a> <span class="sourceLineNo">250</span> * The localized servlet title.<a name="line.250"></a> <span class="sourceLineNo">251</span> * <p><a name="line.251"></a> -<span class="sourceLineNo">252</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.252"></a> +<span class="sourceLineNo">252</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.252"></a> <span class="sourceLineNo">253</span> * <p><a name="line.253"></a> <span class="sourceLineNo">254</span> * Equivalent to the value returned by {@link RestRequest#getServletTitle()}<a name="line.254"></a> <span class="sourceLineNo">255</span> */<a name="line.255"></a> @@ -266,7 +266,7 @@ <span class="sourceLineNo">258</span> /**<a name="line.258"></a> <span class="sourceLineNo">259</span> * The localized servlet description.<a name="line.259"></a> <span class="sourceLineNo">260</span> * <p><a name="line.260"></a> -<span class="sourceLineNo">261</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.261"></a> +<span class="sourceLineNo">261</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.261"></a> <span class="sourceLineNo">262</span> * <p><a name="line.262"></a> <span class="sourceLineNo">263</span> * Equivalent to the value returned by {@link RestRequest#getServletDescription()}<a name="line.263"></a> <span class="sourceLineNo">264</span> */<a name="line.264"></a> @@ -275,7 +275,7 @@ <span class="sourceLineNo">267</span> /**<a name="line.267"></a> <span class="sourceLineNo">268</span> * The localized method summary.<a name="line.268"></a> <span class="sourceLineNo">269</span> * <p><a name="line.269"></a> -<span class="sourceLineNo">270</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.270"></a> +<span class="sourceLineNo">270</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.270"></a> <span class="sourceLineNo">271</span> * <p><a name="line.271"></a> <span class="sourceLineNo">272</span> * Equivalent to the value returned by {@link RestRequest#getMethodSummary()}<a name="line.272"></a> <span class="sourceLineNo">273</span> */<a name="line.273"></a> @@ -284,7 +284,7 @@ <span class="sourceLineNo">276</span> /**<a name="line.276"></a> <span class="sourceLineNo">277</span> * The localized method description.<a name="line.277"></a> <span class="sourceLineNo">278</span> * <p><a name="line.278"></a> -<span class="sourceLineNo">279</span> * Automatically added to properties returned by {@link SerializerSession#getProperties()} and {@link ParserSession#getProperties()}.<a name="line.279"></a> +<span class="sourceLineNo">279</span> * Automatically added to properties returned by {@link SerializerSession#getProperty(String)} and {@link ParserSession#getProperty(String)}.<a name="line.279"></a> <span class="sourceLineNo">280</span> * <p><a name="line.280"></a> <span class="sourceLineNo">281</span> * Equivalent to the value returned by {@link RestRequest#getMethodDescription()}<a name="line.281"></a> <span class="sourceLineNo">282</span> */<a name="line.282"></a> http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/blob/b852a3e8/content/site/apidocs/src-html/org/apache/juneau/rest/RestRequest.html ---------------------------------------------------------------------- diff --git a/content/site/apidocs/src-html/org/apache/juneau/rest/RestRequest.html b/content/site/apidocs/src-html/org/apache/juneau/rest/RestRequest.html index 6177163..5526750 100644 --- a/content/site/apidocs/src-html/org/apache/juneau/rest/RestRequest.html +++ b/content/site/apidocs/src-html/org/apache/juneau/rest/RestRequest.html @@ -465,13 +465,13 @@ <span class="sourceLineNo">457</span> * <p><a name="line.457"></a> <span class="sourceLineNo">458</span> * The URI context contains all the information about the URI of the request, such<a name="line.458"></a> <span class="sourceLineNo">459</span> * as the servlet URI, context path, etc...<a name="line.459"></a> -<span class="sourceLineNo">460</span> * <a name="line.460"></a> +<span class="sourceLineNo">460</span> *<a name="line.460"></a> <span class="sourceLineNo">461</span> * @return The URI context of the request.<a name="line.461"></a> <span class="sourceLineNo">462</span> */<a name="line.462"></a> <span class="sourceLineNo">463</span> public UriContext getUriContext() {<a name="line.463"></a> <span class="sourceLineNo">464</span> if (uriContext == null) {<a name="line.464"></a> <span class="sourceLineNo">465</span> String authority = StringUtils.getAuthorityUri(super.getRequestURL().toString());<a name="line.465"></a> -<span class="sourceLineNo">466</span> uriContext = new UriContext(authority, super.getContextPath(), super.getServletPath(), super.getPathInfo());<a name="line.466"></a> +<span class="sourceLineNo">466</span> uriContext = new UriContext(UriResolution.ROOT_RELATIVE, UriRelativity.RESOURCE, authority, super.getContextPath(), super.getServletPath(), super.getPathInfo());<a name="line.466"></a> <span class="sourceLineNo">467</span> }<a name="line.467"></a> <span class="sourceLineNo">468</span> return uriContext;<a name="line.468"></a> <span class="sourceLineNo">469</span> }<a name="line.469"></a>
