You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@juneau.apache.org by ja...@apache.org on 2018/01/14 16:02:39 UTC
[11/32] juneau git commit: Javadoc updates.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonSerializerSession.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonSerializerSession.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonSerializerSession.java
index 6bb21a9..7730c9c 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonSerializerSession.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonSerializerSession.java
@@ -23,7 +23,7 @@ import org.apache.juneau.transform.*;
/**
* Session object that lives for the duration of a single use of {@link UonSerializer}.
- *
+ *
* <p>
* This class is NOT thread safe.
* It is typically discarded after one-time use although it can be reused within the same thread.
@@ -65,7 +65,7 @@ public class UonSerializerSession extends WriterSerializerSession {
/**
* Returns the {@link UonSerializer#UON_addBeanTypeProperties} setting value for this session.
- *
+ *
* @return The {@link UonSerializer#UON_addBeanTypeProperties} setting value for this session.
*/
@Override /* SerializerSession */
@@ -75,7 +75,7 @@ public class UonSerializerSession extends WriterSerializerSession {
/**
* Converts the specified output target object to an {@link UonWriter}.
- *
+ *
* @param out The output target object.
* @return The output target object wrapped in an {@link UonWriter}.
* @throws Exception
@@ -97,7 +97,7 @@ public class UonSerializerSession extends WriterSerializerSession {
/**
* Workhorse method. Determines the type of object, and then calls the appropriate type-specific serialization
* method.
- *
+ *
* @param out The writer to serialize to.
* @param o The object being serialized.
* @param eType The expected type of the object if this is a bean property.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonUtils.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonUtils.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonUtils.java
index 50290da..7a77546 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonUtils.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonUtils.java
@@ -26,10 +26,10 @@ public final class UonUtils {
/**
* Returns <jk>true</jk> if the specified string needs to be quoted per UON notation.
- *
+ *
* <p>
* For example, strings that start with '(' or '@' or look like boolean or numeric values need to be quoted.
- *
+ *
* @param s The string to test.
* @return <jk>true</jk> if the specified string needs to be quoted per UON notation.
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonWriter.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonWriter.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonWriter.java
index 0476fa0..60f6aa4 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonWriter.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/uon/UonWriter.java
@@ -20,8 +20,9 @@ import org.apache.juneau.serializer.*;
/**
* Specialized writer for serializing UON-encoded text.
- *
- * <h5 class='section'>Notes:</h5>
+ *
+ *
+ * <h5 class='topic'>Notes</h5>
* <ul>
* <li>This class is not intended for external use.
* </ul>
@@ -47,7 +48,7 @@ public final class UonWriter extends SerializerWriter {
/**
* Constructor.
- *
+ *
* @param session The session that created this writer.
* @param out The writer being wrapped.
* @param useWhitespace If <jk>true</jk>, tabs will be used in output.
@@ -67,7 +68,7 @@ public final class UonWriter extends SerializerWriter {
/**
* Serializes the specified simple object as a UON string value.
- *
+ *
* @param o The object being serialized.
* @param isTopAttrName If this is a top-level attribute name we're serializing.
* @return This object (for method chaining).
@@ -126,7 +127,7 @@ public final class UonWriter extends SerializerWriter {
/**
* Appends a boolean value to the output.
- *
+ *
* @param o The boolean value to append to the output.
* @return This object (for method chaining).
* @throws IOException
@@ -138,7 +139,7 @@ public final class UonWriter extends SerializerWriter {
/**
* Appends a numeric value to the output.
- *
+ *
* @param o The numeric value to append to the output.
* @return This object (for method chaining).
* @throws IOException
@@ -160,7 +161,7 @@ public final class UonWriter extends SerializerWriter {
/**
* Appends a URI to the output.
- *
+ *
* @param uri The URI to append to the output.
* @return This object (for method chaining).
* @throws IOException
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingClassMeta.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingClassMeta.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingClassMeta.java
index b585e67..0348594 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingClassMeta.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingClassMeta.java
@@ -26,7 +26,7 @@ public class UrlEncodingClassMeta extends ClassMetaExtended {
/**
* Constructor.
- *
+ *
* @param cm The class that this annotation is defined on.
*/
public UrlEncodingClassMeta(ClassMeta<?> cm) {
@@ -41,7 +41,7 @@ public class UrlEncodingClassMeta extends ClassMetaExtended {
/**
* Returns the {@link UrlEncoding} annotation defined on the class.
- *
+ *
* @return The value of the {@link UrlEncoding} annotation, or <jk>null</jk> if annotation is not specified.
*/
protected UrlEncoding getAnnotation() {
@@ -50,7 +50,7 @@ public class UrlEncodingClassMeta extends ClassMetaExtended {
/**
* Returns the {@link UrlEncoding#expandedParams()} annotation defined on the class.
- *
+ *
* @return The value of the {@link UrlEncoding#expandedParams()} annotation.
*/
protected boolean isExpandedParams() {
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParser.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParser.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParser.java
index c8051b9..e8c67b5 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParser.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParser.java
@@ -19,18 +19,20 @@ import org.apache.juneau.urlencoding.annotation.*;
/**
* Parses URL-encoded text into POJO models.
- *
- * <h5 class='section'>Media types:</h5>
- *
- * Handles <code>Content-Type</code> types: <code>application/x-www-form-urlencoded</code>
- *
- * <h5 class='section'>Description:</h5>
- *
+ *
+ *
+ * <h5 class='topic'>Media types</h5>
+ *
+ * Handles <code>Content-Type</code> types: <code><b>application/x-www-form-urlencoded</b></code>
+ *
+ *
+ * <h5 class='topic'>Description</h5>
+ *
* Parses URL-Encoded text (e.g. <js>"foo=bar&baz=bing"</js>) into POJOs.
- *
+ *
* <p>
* Expects parameter values to be in UON notation.
- *
+ *
* <p>
* This parser uses a state machine, which makes it very fast and efficient.
*/
@@ -44,7 +46,7 @@ public class UrlEncodingParser extends UonParser {
/**
* Configuration property: Parser bean property collections/arrays as separate key/value pairs
- *
+ *
* <h5 class='section'>Property:</h5>
* <ul>
* <li><b>Name:</b> <js>"UrlEncodingParser.expandedParams.b"</js>
@@ -58,22 +60,22 @@ public class UrlEncodingParser extends UonParser {
* <li class='ja'>{@link UrlEncoding#expandedParams()}
* </ul>
* </ul>
- *
+ *
* <h5 class='section'>Description:</h5>
* <p>
* This is the parser-side equivalent of the {@link #URLENC_expandedParams} setting.
- *
+ *
* <p>
* If <jk>false</jk>, serializing the array <code>[1,2,3]</code> results in <code>?key=$a(1,2,3)</code>.
* <br>If <jk>true</jk>, serializing the same array results in <code>?key=1&key=2&key=3</code>.
- *
+ *
* <h5 class='section'>Example:</h5>
* <p class='bcode'>
* <jk>public class</jk> A {
* <jk>public</jk> String[] f1;
* <jk>public</jk> List<String> f2;
* }
- *
+ *
* UrlEncodingParser p1 = UrlEncodingParser.<jsf>DEFAULT</jsf>;
* UrlEncodingParser p2 = UrlEncodingParser.<jsm>create</jsm>().expandedParams().build();
*
@@ -81,10 +83,10 @@ public class UrlEncodingParser extends UonParser {
*
* A a2 = p2.parse(<js>"f1=a&f1=b&f2=c&f2=d"</js>, A.<jk>class</jk>);
* </p>
- *
+ *
* <p>
* This option only applies to beans.
- *
+ *
* <h5 class='section'>Notes:</h5>
* <ul>
* <li>If parsing multi-part parameters, it's highly recommended to use Collections or Lists
@@ -112,7 +114,7 @@ public class UrlEncodingParser extends UonParser {
/**
* Constructor.
- *
+ *
* @param ps The property store containing all the settings for this object.
*/
public UrlEncodingParser(PropertyStore ps) {
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserBuilder.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserBuilder.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserBuilder.java
index d996452..79e14b4 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserBuilder.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserBuilder.java
@@ -35,7 +35,7 @@ public class UrlEncodingParserBuilder extends UonParserBuilder {
/**
* Constructor.
- *
+ *
* @param ps The initial configuration settings for this builder.
*/
public UrlEncodingParserBuilder(PropertyStore ps) {
@@ -54,10 +54,10 @@ public class UrlEncodingParserBuilder extends UonParserBuilder {
/**
* Configuration property: Serialize bean property collections/arrays as separate key/value pairs.
- *
+ *
* <p>
* This is the parser-side equivalent of the {@link UrlEncodingParser#URLENC_expandedParams} setting.
- *
+ *
* <h5 class='section'>See Also:</h5>
* <ul>
* <li class='jf'>{@link UrlEncodingParser#URLENC_expandedParams}
@@ -74,10 +74,10 @@ public class UrlEncodingParserBuilder extends UonParserBuilder {
/**
* Configuration property: Serialize bean property collections/arrays as separate key/value pairs.
- *
+ *
* <p>
* Shortcut for calling <code>expandedParams(<jk>true</jk>)</code>.
- *
+ *
* <h5 class='section'>See Also:</h5>
* <ul>
* <li class='jf'>{@link UrlEncodingParser#URLENC_expandedParams}
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserSession.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserSession.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserSession.java
index b843046..2207577 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserSession.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingParserSession.java
@@ -25,7 +25,7 @@ import org.apache.juneau.uon.*;
/**
* Session object that lives for the duration of a single use of {@link UrlEncodingParser}.
- *
+ *
* <p>
* This class is NOT thread safe.
* It is typically discarded after one-time use although it can be reused against multiple inputs.
@@ -37,7 +37,7 @@ public class UrlEncodingParserSession extends UonParserSession {
/**
* Create a new session using properties specified in the context.
- *
+ *
* @param ctx
* The context creating this session object.
* The context contains all the configuration settings for this object.
@@ -59,7 +59,7 @@ public class UrlEncodingParserSession extends UonParserSession {
/**
* Returns <jk>true</jk> if the specified bean property should be expanded as multiple key-value pairs.
- *
+ *
* @param pMeta The metadata on the bean property.
* @return <jk>true</jk> if the specified bean property should be expanded as multiple key-value pairs.
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializer.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializer.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializer.java
index 2c669b8..c7ea512 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializer.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializer.java
@@ -18,18 +18,21 @@ import org.apache.juneau.uon.*;
/**
* Serializes POJO models to URL-encoded notation with UON-encoded values (a notation for URL-encoded query paramter values).
- *
+ *
+ *
* <h5 class='section'>Media types:</h5>
- *
- * Handles <code>Accept</code> types: <code>application/x-www-form-urlencoded</code>
+ *
+ * Handles <code>Accept</code> types: <code><b>application/x-www-form-urlencoded</b></code>
* <p>
- * Produces <code>Content-Type</code> types: <code>application/x-www-form-urlencoded</code>
- *
- * <h5 class='section'>Description:</h5>
- *
- * This serializer provides several serialization options. Typically, one of the predefined DEFAULT serializers will be sufficient.
- * However, custom serializers can be constructed to fine-tune behavior.
- *
+ * Produces <code>Content-Type</code> types: <code><b>application/x-www-form-urlencoded</b></code>
+ *
+ *
+ * <h5 class='topic'>Description</h5>
+ *
+ * This serializer provides several serialization options.
+ * <br>Typically, one of the predefined DEFAULT serializers will be sufficient.
+ * <br>However, custom serializers can be constructed to fine-tune behavior.
+ *
* <p>
* The following shows a sample object defined in Javascript:
* <p class='bcode'>
@@ -54,7 +57,7 @@ import org.apache.juneau.uon.*;
* ]
* }
* </p>
- *
+ *
* <p>
* Using the "strict" syntax defined in this document, the equivalent URL-encoded notation would be as follows:
* <p class='bcode'>
@@ -77,16 +80,16 @@ import org.apache.juneau.uon.*;
* )
* )
* </p>
- *
+ *
* <h5 class='section'>Example:</h5>
* <p class='bcode'>
* <jc>// Serialize a Map</jc>
* Map m = <jk>new</jk> ObjectMap(<js>"{a:'b',c:1,d:false,e:['f',1,false],g:{h:'i'}}"</js>);
- *
+ *
* <jc>// Serialize to value equivalent to JSON.</jc>
* <jc>// Produces "a=b&c=1&d=false&e=@(f,1,false)&g=(h=i)"</jc>
* String s = UrlEncodingSerializer.<jsf>DEFAULT</jsf>.serialize(s);
- *
+ *
* <jc>// Serialize a bean</jc>
* <jk>public class</jk> Person {
* <jk>public</jk> Person(String s);
@@ -95,16 +98,16 @@ import org.apache.juneau.uon.*;
* <jk>public</jk> Address getAddress();
* <jk>public boolean</jk> deceased;
* }
- *
+ *
* <jk>public class</jk> Address {
* <jk>public</jk> String getStreet();
* <jk>public</jk> String getCity();
* <jk>public</jk> String getState();
* <jk>public int</jk> getZip();
* }
- *
+ *
* Person p = <jk>new</jk> Person(<js>"John Doe"</js>, 23, <js>"123 Main St"</js>, <js>"Anywhere"</js>, <js>"NY"</js>, 12345, <jk>false</jk>);
- *
+ *
* <jc>// Produces "name=John+Doe&age=23&address=(street='123+Main+St',city=Anywhere,state=NY,zip=12345)&deceased=false"</jc>
* String s = UrlEncodingSerializer.<jsf>DEFAULT</jsf>.serialize(s);
* </p>
@@ -119,7 +122,7 @@ public class UrlEncodingSerializer extends UonSerializer {
/**
* Configuration property: Serialize bean property collections/arrays as separate key/value pairs.
- *
+ *
* <h5 class='section'>Property:</h5>
* <ul>
* <li><b>Name:</b> <js>"UrlEncodingSerializer.expandedParams.b"</js>
@@ -132,15 +135,15 @@ public class UrlEncodingSerializer extends UonSerializer {
* <li class='jm'>{@link UrlEncodingSerializerBuilder#expandedParams()}
* </ul>
* </ul>
- *
+ *
* <h5 class='section'>Description:</h5>
* <p>
* If <jk>false</jk>, serializing the array <code>[1,2,3]</code> results in <code>?key=$a(1,2,3)</code>.
* <br>If <jk>true</jk>, serializing the same array results in <code>?key=1&key=2&key=3</code>.
- *
+ *
* <p>
* This option only applies to beans.
- *
+ *
* <h5 class='section'>Notes:</h5>
* <ul>
* <li>If parsing multi-part parameters, it's highly recommended to use <code>Collections</code> or <code>Lists</code>
@@ -155,20 +158,20 @@ public class UrlEncodingSerializer extends UonSerializer {
* <jk>public</jk> String[] f1 = {<js>"a"</js>,<js>"b"</js>};
* <jk>public</jk> List<String> f2 = Arrays.<jsm>asList</jsm>(<jk>new</jk> String[]{<js>"c"</js>,<js>"d"</js>});
* }
- *
+ *
* <jc>// Normal serializer.</jc>
* WriterSerializer s1 = UrlEncodingSerializer.<jsf>DEFAULT</jsf>;
*
* <jc>// Expanded-params serializer.</jc>
* WriterSerializer s2 = UrlEncodingSerializer.<jsm>create</jsm>().expandedParams().build();
- *
- * <jc>// Produces "f1=(a,b)&f2=(c,d)"</jc>
+ *
+ * <jc>// Produces "f1=(a,b)&f2=(c,d)"</jc>
* String ss1 = s1.serialize(<jk>new</jk> A());
*
* <jc>// Produces "f1=a&f1=b&f2=c&f2=d"</jc>
* String ss2 = s2.serialize(<jk>new</jk> A()); <jc>
* </p>
- *
+ *
*/
public static final String URLENC_expandedParams = PREFIX + "expandedParams.b";
@@ -201,7 +204,7 @@ public class UrlEncodingSerializer extends UonSerializer {
/**
* Constructor.
- *
+ *
* @param ps The property store containing all the settings for this object.
*/
public Expanded(PropertyStore ps) {
@@ -216,7 +219,7 @@ public class UrlEncodingSerializer extends UonSerializer {
/**
* Constructor.
- *
+ *
* @param ps The property store containing all the settings for this object.
*/
public Readable(PropertyStore ps) {
@@ -231,7 +234,7 @@ public class UrlEncodingSerializer extends UonSerializer {
/**
* Constructor.
- *
+ *
* @param ps The property store containing all the settings for this object.
*/
public PlainText(PropertyStore ps) {
@@ -249,7 +252,7 @@ public class UrlEncodingSerializer extends UonSerializer {
/**
* Constructor.
- *
+ *
* @param ps
* The property store containing all the settings for this object.
*/
@@ -259,7 +262,7 @@ public class UrlEncodingSerializer extends UonSerializer {
/**
* Constructor.
- *
+ *
* @param ps
* The property store containing all the settings for this object.
* @param produces
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerBuilder.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerBuilder.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerBuilder.java
index 20bcc68..b45f82c 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerBuilder.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerBuilder.java
@@ -35,7 +35,7 @@ public class UrlEncodingSerializerBuilder extends UonSerializerBuilder {
/**
* Constructor.
- *
+ *
* @param ps The initial configuration settings for this builder.
*/
public UrlEncodingSerializerBuilder(PropertyStore ps) {
@@ -54,11 +54,11 @@ public class UrlEncodingSerializerBuilder extends UonSerializerBuilder {
/**
* Configuration property: Serialize bean property collections/arrays as separate key/value pairs.
- *
+ *
* <p>
* If <jk>false</jk>, serializing the array <code>[1,2,3]</code> results in <code>?key=$a(1,2,3)</code>.
* <br>If <jk>true</jk>, serializing the same array results in <code>?key=1&key=2&key=3</code>.
- *
+ *
* <h5 class='section'>See Also:</h5>
* <ul>
* <li class='jf'>{@link UrlEncodingSerializer#URLENC_expandedParams}
@@ -75,10 +75,10 @@ public class UrlEncodingSerializerBuilder extends UonSerializerBuilder {
/**
* Configuration property: Serialize bean property collections/arrays as separate key/value pairs.
- *
+ *
* <p>
* Shortcut for calling <code>expandedParams(<jk>true</jk>)</code>.
- *
+ *
* <h5 class='section'>See Also:</h5>
* <ul>
* <li class='jf'>{@link UrlEncodingSerializer#URLENC_expandedParams}
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerSession.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerSession.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerSession.java
index 8a56c09..f0d3bfc 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerSession.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/UrlEncodingSerializerSession.java
@@ -26,7 +26,7 @@ import org.apache.juneau.uon.*;
/**
* Session object that lives for the duration of a single use of {@link UrlEncodingSerializer}.
- *
+ *
* <p>
* This class is NOT thread safe.
* It is typically discarded after one-time use although it can be reused within the same thread.
@@ -38,7 +38,7 @@ public class UrlEncodingSerializerSession extends UonSerializerSession {
/**
* Constructor.
- *
+ *
* @param ctx
* The context creating this session object.
* The context contains all the configuration settings for this object.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/annotation/UrlEncoding.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/annotation/UrlEncoding.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/annotation/UrlEncoding.java
index d8b9d2d..5a0d4a7 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/annotation/UrlEncoding.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/urlencoding/annotation/UrlEncoding.java
@@ -31,7 +31,7 @@ public @interface UrlEncoding {
/**
* When true, bean properties of type array or Collection will be expanded into multiple key/value pairings.
- *
+ *
* <p>
* This annotation is identical in behavior to using the {@link UrlEncodingSerializer#URLENC_expandedParams}
* and {@link UrlEncodingParser#URLENC_expandedParams} properties, but applies to only instances of this bean.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AList.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AList.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AList.java
index 2c5e766..45aa3fc 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AList.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AList.java
@@ -16,14 +16,14 @@ import java.util.*;
/**
* An extension of {@link LinkedList} with a convenience {@link #append(Object)} method.
- *
+ *
* <p>
* Primarily used for testing purposes for quickly creating populated lists.
* <p class='bcode'>
* <jc>// Example:</jc>
* List<String> l = <jk>new</jk> AList<String>().append(<js>"foo"</js>).append(<js>"bar"</js>);
* </p>
- *
+ *
* @param <T> The entry type.
*/
@SuppressWarnings({"serial","unchecked"})
@@ -31,7 +31,7 @@ public final class AList<T> extends LinkedList<T> {
/**
* Adds an entry to this list.
- *
+ *
* @param t The entry to add to this list.
* @return This object (for method chaining).
*/
@@ -42,7 +42,7 @@ public final class AList<T> extends LinkedList<T> {
/**
* Adds multiple entries to this list.
- *
+ *
* @param t The entries to add to this list.
* @return This object (for method chaining).
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AMap.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AMap.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AMap.java
index e6a8420..0ccfe9a 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AMap.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/AMap.java
@@ -16,7 +16,7 @@ import java.util.*;
/**
* An extension of {@link LinkedHashMap} with a convenience {@link #append(Object,Object)} method.
- *
+ *
* <p>
* Primarily used for testing purposes for quickly creating populated maps.
* <p class='bcode'>
@@ -24,7 +24,7 @@ import java.util.*;
* Map<String,Integer> m = <jk>new</jk> AMap<String,Integer>()
* .append(<js>"foo"</js>,1).append(<js>"bar"</js>,2);
* </p>
- *
+ *
* @param <K> The key type.
* @param <V> The value type.
*/
@@ -33,7 +33,7 @@ public final class AMap<K,V> extends LinkedHashMap<K,V> {
/**
* Adds an entry to this map.
- *
+ *
* @param k The key.
* @param v The value.
* @return This object (for method chaining).
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ASet.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ASet.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ASet.java
index f6fe987..036cb21 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ASet.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ASet.java
@@ -16,14 +16,14 @@ import java.util.*;
/**
* An extension of {@link LinkedHashSet} with a convenience {@link #append(Object)} method.
- *
+ *
* <p>
* Primarily used for testing purposes for quickly creating populated sets.
* <p class='bcode'>
* <jc>// Example:</jc>
* Set<String> s = <jk>new</jk> ASet<String>().append(<js>"foo"</js>).append(<js>"bar"</js>);
* </p>
- *
+ *
* @param <T> The entry type.
*/
@SuppressWarnings({"serial","unchecked"})
@@ -31,7 +31,7 @@ public final class ASet<T> extends LinkedHashSet<T> {
/**
* Adds an entry to this set.
- *
+ *
* @param t The entry to add to this set.
* @return This object (for method chaining).
*/
@@ -42,7 +42,7 @@ public final class ASet<T> extends LinkedHashSet<T> {
/**
* Adds multiple entries to this set.
- *
+ *
* @param t The entries to add to this set.
* @return This object (for method chaining).
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/Args.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/Args.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/Args.java
index b16e16d..fdeca7f 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/Args.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/Args.java
@@ -22,17 +22,17 @@ import org.apache.juneau.internal.*;
/**
* Utility class to make it easier to work with command-line arguments pass in through a
* <code>main(String[] args)</code> method.
- *
+ *
* <p>
* Used to parse command-line arguments of the form
* <js>"[zero or more main arguments] [zero or more optional arguments]"</js>.
- *
+ *
* <p>
* The format of a main argument is a token that does not start with <js>'-'</js>.
- *
+ *
* <p>
* The format of an optional argument is <js>"-argName [zero or more tokens]"</js>.
- *
+ *
* <h6 class='topic'>Command-line examples</h6>
* <ul>
* <li><code>java com.sample.MyClass mainArg1</code>
@@ -43,62 +43,62 @@ import org.apache.juneau.internal.*;
* <li><code>java com.sample.MyClass mainArg1 -optArg1 optArg1Val1 optArg1Val2</code>
* <li><code>java com.sample.MyClass mainArg1 -optArg1 optArg1Val1 -optArg1 optArg1Val2</code>
* </ul>
- *
- * <h5 class='section'>Examples:</h5>
+ *
+ * <h5 class='section'>Example:</h5>
* <p class='bcode'>
- *
+ *
* <jc>// Main method with arguments</jc>
* <jk>public static void</jk> <jsm>main</jsm>(String[] args) {
- *
+ *
* <jc>// Wrap in Args</jc>
* Args a = new Args(args);
- *
+ *
* <jc>// One main argument</jc>
* <jc>// a1</jc>
* String a1 = a.getArg(0); <jc>// "a1"</jc>
* String a2 = a.getArg(1); <jc>// null</jc>
- *
+ *
* <jc>// Two main arguments</jc>
* <jc>// a1 a2</jc>
* String a1 = a.getArg(0); <jc>// "a1"</jc>
* String a2 = a.getArg(1); <jc>// "a2"</jc>
- *
+ *
* <jc>// One main argument and one optional argument with no value</jc>
* <jc>// a1 -a2</jc>
* String a1 = a.getArg(0);
* <jk>boolean</jk> hasA2 = a.hasArg(<js>"a2"</js>); <jc>// true</jc>
* <jk>boolean</jk> hasA3 = a.hasArg(<js>"a3"</js>); <jc>// false</jc>
- *
+ *
* <jc>// One main argument and one optional argument with one value</jc>
* <jc>// a1 -a2 v2</jc>
* String a1 = a.getArg(0);
* String a2 = a.getArg(<js>"a2"</js>); <jc>// "v2"</jc>
* String a3 = a.getArg(<js>"a3"</js>); <jc>// null</jc>
- *
+ *
* <jc>// One main argument and one optional argument with two values</jc>
* <jc>// a1 -a2 v2a v2b</jc>
* String a1 = a.getArg(0);
* List<String> a2 = a.getArgs(<js>"a2"</js>); <jc>// Contains ["v2a","v2b"]</jc>
* List<String> a3 = a.getArgs(<js>"a3"</js>); <jc>// Empty list</jc>
- *
+ *
* <jc>// Same as previous, except specify optional argument name multiple times</jc>
* <jc>// a1 -a2 v2a -a2 v2b</jc>
* String a1 = a.getArg(0);
* List<String> a2 = a.getArgs(<js>"a2"</js>); <jc>// Contains ["v2a","v2b"]</jc>
* }
* </p>
- *
+ *
* <p>
* Main arguments are available through numeric string keys (e.g. <js>"0"</js>, <js>"1"</js>, ...).
* So you could use the {@link ObjectMap} API to convert main arguments directly to POJOs, such as an <code>Enum</code>
* <p class='bcode'>
* <jc>// Get 1st main argument as an Enum</jc>
* MyEnum e = a.get(MyEnum.<jk>class</jk>, <js>"0"</js>);
- *
+ *
* <jc>// Get 1st main argument as an integer</jc>
* int i = a.get(<jk>int</jk>.<jk>class</jk>, <js>"0"</js>);
* </p>
- *
+ *
* <p>
* Equivalent operations are available on optional arguments through the {@link #getArg(Class, String)} method.
*/
@@ -108,7 +108,7 @@ public final class Args extends ObjectMap {
/**
* Constructor.
- *
+ *
* @param args Arguments passed in through a <code>main(String[] args)</code> method.
*/
public Args(String[] args) {
@@ -142,7 +142,7 @@ public final class Args extends ObjectMap {
/**
* Constructor.
- *
+ *
* @param args Arguments passed in as a raw command line.
*/
public Args(String args) {
@@ -151,29 +151,29 @@ public final class Args extends ObjectMap {
/**
* Returns main argument at the specified index, or <jk>null</jk> if the index is out of range.
- *
+ *
* <p>
* Can be used in conjunction with {@link #hasArg(int)} to check for existence of arg.
* <p class='bcode'>
* <jc>// Check for no arguments</jc>
* <jk>if</jk> (! args.hasArg(0))
* printUsageAndExit();
- *
+ *
* <jc>// Get the first argument</jc>
* String firstArg = args.getArg(0);
* </p>
- *
+ *
* <p>
* Since main arguments are stored as numeric keys, this method is essentially equivalent to...
* <p class='bcode'>
* <jc>// Check for no arguments</jc>
* <jk>if</jk> (! args.containsKey(<js>"0"</js>))
* printUsageAndExit();
- *
+ *
* <jc>// Get the first argument</jc>
* String firstArg = args.getString("0");
* </p>
- *
+ *
* @param i The index position of the main argument (zero-indexed).
* @return The main argument value, or <js>""</js> if argument doesn't exist at that position.
*/
@@ -183,7 +183,7 @@ public final class Args extends ObjectMap {
/**
* Returns <jk>true</jk> if argument exists at specified index.
- *
+ *
* @param i The zero-indexed position of the argument.
* @return <jk>true</jk> if argument exists at specified index.
*/
@@ -193,10 +193,10 @@ public final class Args extends ObjectMap {
/**
* Returns the optional argument value, or blank if the optional argument was not specified.
- *
+ *
* <p>
* If the optional arg has multiple values, returns values as a comma-delimited list.
- *
+ *
* @param name The optional argument name.
* @return The optional argument value, or blank if the optional argument was not specified.
*/
@@ -211,17 +211,17 @@ public final class Args extends ObjectMap {
/**
* Returns the optional argument value converted to the specified object type.
- *
+ *
* <p>
* If the optional arg has multiple values, returns only the first converted value.
- *
+ *
* <h5 class='section'>Example:</h5>
* <p class='bcode'>
* <jc>// Command: java com.sample.MyClass -verbose true -debug 5</jc>
* <jk>boolean</jk> b = args.getArg(<jk>boolean</jk>.<jk>class</jk>, <js>"verbose"</js>);
* <jk>int</jk> i = args.getArg(<jk>int</jk>.<jk>class</jk>, <js>"debug"</js>);
* </p>
- *
+ *
* @param c The class type to convert the value to.
* @param <T> The class type to convert the value to.
* @param name The optional argument name.
@@ -236,14 +236,14 @@ public final class Args extends ObjectMap {
/**
* Returns the optional argument values as a list of strings.
- *
+ *
* <h5 class='section'>Example:</h5>
* <p class='bcode'>
* <jc>// Command: java com.sample.MyClass -extraArgs foo bar baz</jc>
* List<String> l1 = args.getArgs(<js>"extraArgs"</js>); <jc>// ['foo','bar','baz']</jc>
* List<String> l2 = args.getArgs(<js>"nonExistentArgs"</js>); <jc>// An empty list</jc>
* </p>
- *
+ *
* @param name The optional argument name.
* @return The optional argument values, or an empty list if the optional argument was not specified.
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/CalendarUtils.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/CalendarUtils.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/CalendarUtils.java
index 644b6b7..7bf4f6b 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/CalendarUtils.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/CalendarUtils.java
@@ -36,12 +36,12 @@ public class CalendarUtils {
/**
* Transform to ISO8601 date-time-local strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"2001-07-04T15:30:45"</js>
* </ul>
- *
+ *
* <h6 class='topic'>Example input:</h6>
* <ul>
* <li><js>"2001-07-04T15:30:45"</js>
@@ -56,13 +56,13 @@ public class CalendarUtils {
/**
* Transform to ISO8601 date-time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"2001-07-04T15:30:45-05:00"</js>
* <li><js>"2001-07-04T15:30:45Z"</js>
* </ul>
- *
+ *
* <h6 class='topic'>Example input:</h6>
* <ul>
* <li><js>"2001-07-04T15:30:45-05:00"</js>
@@ -78,7 +78,7 @@ public class CalendarUtils {
/**
* Same as {@link CalendarUtils.Format#ISO8601_DT}, except always serializes in GMT.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <js>"2001-07-04T15:30:45Z"</js>
*/
@@ -86,7 +86,7 @@ public class CalendarUtils {
/**
* Same as {@link CalendarUtils.Format#ISO8601_DT} except serializes to millisecond precision.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <js>"2001-07-04T15:30:45.123Z"</js>
*/
@@ -94,7 +94,7 @@ public class CalendarUtils {
/**
* Same as {@link CalendarUtils.Format#ISO8601_DTZ} except serializes to millisecond precision.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <js>"2001-07-04T15:30:45.123"</js>
*/
@@ -102,7 +102,7 @@ public class CalendarUtils {
/**
* ISO8601 date only.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <js>"2001-07-04"</js>
*/
@@ -110,7 +110,7 @@ public class CalendarUtils {
/**
* Transform to {@link String Strings} using the {@code Date.toString()} method.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"Wed Jul 04 15:30:45 EST 2001"</js>
@@ -120,7 +120,7 @@ public class CalendarUtils {
/**
* Transform to RFC2822 date-time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"Sat, 03 Mar 2001 10:11:12 +0000"</js> <jc>// en_US</jc>
@@ -132,7 +132,7 @@ public class CalendarUtils {
/**
* Same as {@link CalendarUtils.Format#RFC2822_DT}, except always serializes in GMT.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"Sat, 03 Mar 2001 10:11:12 GMT"</js> <jc>// en_US</jc>
@@ -144,7 +144,7 @@ public class CalendarUtils {
/**
* Transform to RFC2822 date strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"03 Mar 2001"</js> <jc>// en_US</jc>
@@ -156,7 +156,7 @@ public class CalendarUtils {
/**
* Transform to simple <js>"yyyy/MM/dd HH:mm:ss"</js> date-time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"2001/03/03 10:11:12"</js>
@@ -166,7 +166,7 @@ public class CalendarUtils {
/**
* Transform to simple <js>"yyyy/MM/dd"</js> date strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"2001/03/03"</js>
@@ -176,7 +176,7 @@ public class CalendarUtils {
/**
* Transform to simple <js>"HH:mm:ss"</js> time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"10:11:12"</js>
@@ -186,7 +186,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#FULL} date strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"Saturday, March 3, 2001"</js> <jc>// en_US</jc>
@@ -198,7 +198,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#LONG} date strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"March 3, 2001"</js> <jc>// en_US</jc>
@@ -210,7 +210,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#MEDIUM} date strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"Mar 3, 2001"</js> <jc>// en_US</jc>
@@ -222,7 +222,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#SHORT} date strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"3/3/01"</js> <jc>// en_US</jc>
@@ -234,7 +234,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#FULL} time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"10:11:12 AM GMT"</js> <jc>// en_US</jc>
@@ -246,7 +246,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#LONG} time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"10:11:12 AM GMT"</js> <jc>// en_US</jc>
@@ -258,7 +258,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#MEDIUM} time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"10:11:12 AM"</js> <jc>// en_US</jc>
@@ -270,7 +270,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#SHORT} time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"10:11 AM"</js> <jc>// en_US</jc>
@@ -282,7 +282,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#FULL} date-time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"Saturday, March 3, 2001 10:11:12 AM GMT"</js> <jc>// en_US</jc>
@@ -294,7 +294,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#LONG} date-time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"March 3, 2001 10:11:12 AM GMT"</js> <jc>// en_US</jc>
@@ -306,7 +306,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#MEDIUM} date-time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"Mar 3, 2001 10:11:12 AM"</js> <jc>// en_US</jc>
@@ -318,7 +318,7 @@ public class CalendarUtils {
/**
* Transform to {@link DateFormat#SHORT} date-time strings.
- *
+ *
* <h5 class='section'>Example output:</h5>
* <ul>
* <li><js>"3/3/01 10:11 AM"</js> <jc>// en_US</jc>
@@ -416,7 +416,7 @@ public class CalendarUtils {
/**
* Converts the specified calendar to a string of the specified format.
- *
+ *
* @param c The calendar to serialize.
* @param format The date format.
* @param locale The locale to use. If <jk>null</jk>, uses {@link Locale#getDefault()}.
@@ -481,7 +481,7 @@ public class CalendarUtils {
/**
* Converts the specified date to a string of the specified format.
- *
+ *
* @param format The date format.
* @param d The date to serialize.
* @param locale The locale to use. If <jk>null</jk>, uses {@link Locale#getDefault()}.
@@ -547,7 +547,7 @@ public class CalendarUtils {
/**
* Converts the specified serialized date back into a {@link Calendar} object.
- *
+ *
* @param format The date format.
* @param in The serialized date.
* @param locale
@@ -619,7 +619,7 @@ public class CalendarUtils {
/**
* Converts the specified serialized date back into a {@link Date} object.
- *
+ *
* @param format The date format.
* @param in The serialized date.
* @param locale
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderBasic.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderBasic.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderBasic.java
index 99114c2..327540e 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderBasic.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderBasic.java
@@ -17,7 +17,7 @@ import java.util.*;
/**
* Utility class for finding resources for a class.
- *
+ *
* <p>
* Same as {@link ClasspathResourceFinderSimple}, but if the resource cannot be found in the classpath, then an attempt
* is made to look in the JVM working directory.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderSimple.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderSimple.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderSimple.java
index bdec620..6e0ada9 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderSimple.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceFinderSimple.java
@@ -20,10 +20,10 @@ import java.util.ResourceBundle.*;
/**
* Utility class for finding resources for a class.
- *
+ *
* <p>
* Same as {@link Class#getResourceAsStream(String)} except looks for resources with localized file names.
- *
+ *
* <p>
* If the <code>locale</code> is specified, then we look for resources whose name matches that locale.
* For example, if looking for the resource <js>"MyResource.txt"</js> for the Japanese locale, we will look for
@@ -72,7 +72,7 @@ public class ClasspathResourceFinderSimple implements ClasspathResourceFinder {
/**
* Returns the candidate file names for the specified file name in the specified locale.
- *
+ *
* <p>
* For example, if looking for the <js>"MyResource.txt"</js> file in the Japanese locale, the iterator will return
* names in the following order:
@@ -81,10 +81,10 @@ public class ClasspathResourceFinderSimple implements ClasspathResourceFinder {
* <li><js>"MyResource_ja.txt"</js>
* <li><js>"MyResource.txt"</js>
* </ol>
- *
+ *
* <p>
* If the locale is <jk>null</jk>, then it will only return <js>"MyResource.txt"</js>.
- *
+ *
* @param fileName The name of the file to get candidate file names on.
* @param l The locale.
* @return An iterator of file names to look at.
@@ -124,7 +124,7 @@ public class ClasspathResourceFinderSimple implements ClasspathResourceFinder {
/**
* Returns the candidate locales for the specified locale.
- *
+ *
* <p>
* For example, if <code>locale</code> is <js>"ja_JP"</js>, then this method will return:
* <ol>
@@ -132,7 +132,7 @@ public class ClasspathResourceFinderSimple implements ClasspathResourceFinder {
* <li><js>"ja"</js>
* <li><js>""</js>
* </ol>
- *
+ *
* @param locale The locale to get the list of candidate locales for.
* @return The list of candidate locales.
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceManager.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceManager.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceManager.java
index 4dcb5c7..8d734cd 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceManager.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ClasspathResourceManager.java
@@ -60,7 +60,7 @@ public final class ClasspathResourceManager {
/**
* Finds the resource with the given name.
- *
+ *
* @param name Name of the desired resource.
* @return An input stream to the object, or <jk>null</jk> if the resource could not be found.
* @throws IOException
@@ -71,7 +71,7 @@ public final class ClasspathResourceManager {
/**
* Finds the resource with the given name for the specified locale and returns it as an input stream.
- *
+ *
* @param name Name of the desired resource.
* @param locale The locale. Can be <jk>null</jk>.
* @return An input stream to the object, or <jk>null</jk> if the resource could not be found.
@@ -116,7 +116,7 @@ public final class ClasspathResourceManager {
/**
* Finds the resource with the given name and converts it to a simple string.
- *
+ *
* @param name Name of the desired resource.
* @return The resource converted to a string, or <jk>null</jk> if the resource could not be found.
* @throws IOException
@@ -127,7 +127,7 @@ public final class ClasspathResourceManager {
/**
* Finds the resource with the given name and converts it to a simple string.
- *
+ *
* @param baseClass
* Overrides the default class to use for retrieving the classpath resource.
* <br>If <jk>null<jk>, uses the base class passed in through the constructor of this class.
@@ -141,7 +141,7 @@ public final class ClasspathResourceManager {
/**
* Finds the resource with the given name and converts it to a simple string.
- *
+ *
* @param name Name of the desired resource.
* @param locale The locale. Can be <jk>null</jk>.
* @return The resource converted to a string, or <jk>null</jk> if the resource could not be found.
@@ -153,7 +153,7 @@ public final class ClasspathResourceManager {
/**
* Finds the resource with the given name and converts it to a simple string.
- *
+ *
* @param baseClass
* Overrides the default class to use for retrieving the classpath resource.
* <br>If <jk>null<jk>, uses the base class passed in through the constructor of this class.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/IOPipe.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/IOPipe.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/IOPipe.java
index 5e4d7f0..53bec8f 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/IOPipe.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/IOPipe.java
@@ -22,7 +22,7 @@ import org.apache.juneau.internal.*;
/**
* A utility class for piping input streams and readers to output streams and writers.
- *
+ *
* <p>
* A typical usage is as follows...
* <p class='bcode'>
@@ -30,7 +30,7 @@ import org.apache.juneau.internal.*;
* Writer out = getWriter();
* IOPipe.create(in, out).closeOut().run();
* </p>
- *
+ *
* <p>
* By default, the input stream is closed and the output stream is not.
* This can be changed by calling {@link #closeOut()} and {@link #close(boolean, boolean)}.
@@ -62,7 +62,7 @@ public class IOPipe {
/**
* Creates a new pipe with the specified input and output.
- *
+ *
* @param input The input. Must be one of the following types: Reader, InputStream, CharSequence.
* @param output The output. Must be one of the following types: Writer, OutputStream.
* @return This object (for method chaining).
@@ -73,7 +73,7 @@ public class IOPipe {
/**
* Close output after piping.
- *
+ *
* @return This object (for method chaining).
*/
public IOPipe closeOut() {
@@ -83,7 +83,7 @@ public class IOPipe {
/**
* Specifies whether to close the input and output after piping.
- *
+ *
* @param in Close input stream. Default is <jk>true</jk>.
* @param out Close output stream. Default is <jk>false</jk>.
* @return This object (for method chaining).
@@ -96,7 +96,7 @@ public class IOPipe {
/**
* Specifies the temporary buffer size.
- *
+ *
* @param buffSize The buffer size. Default is <code>1024</code>.
* @return This object (for method chaining).
*/
@@ -108,10 +108,10 @@ public class IOPipe {
/**
* Specifies whether the content should be piped line-by-line.
- *
+ *
* <p>
* This can be useful if you're trying to pipe console-based input.
- *
+ *
* @param byLines Pipe content line-by-line. Default is <jk>false</jk>.
* @return This object (for method chaining).
*/
@@ -122,7 +122,7 @@ public class IOPipe {
/**
* Same as calling {@link #byLines()} with <jk>true</jk>.
- *
+ *
* @return This object (for method chaining).
*/
public IOPipe byLines() {
@@ -132,7 +132,7 @@ public class IOPipe {
/**
* Specifies a line processor that can be used to process lines before they're piped to the output.
- *
+ *
* @param lineProcessor The line processor.
* @return This object (for method chaining).
*/
@@ -147,7 +147,7 @@ public class IOPipe {
public interface LineProcessor {
/**
* Process the specified line.
- *
+ *
* @param line The line to process.
* @return The processed line.
*/
@@ -156,7 +156,7 @@ public class IOPipe {
/**
* Performs the piping of the input to the output.
- *
+ *
* @return The number of bytes (if streams) or characters (if readers/writers) piped.
* @throws IOException
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ManifestFile.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ManifestFile.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ManifestFile.java
index 25c2ecd..67c7bf4 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ManifestFile.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/ManifestFile.java
@@ -23,7 +23,7 @@ import org.apache.juneau.*;
/**
* Utility class for working with Jar manifest files.
- *
+ *
* <p>
* Copies the contents of a {@link Manifest} into an {@link ObjectMap} so that the various convenience methods on that
* class can be used to retrieve values.
@@ -34,7 +34,7 @@ public class ManifestFile extends ObjectMap {
/**
* Create an instance of this class from a manifest file on the file system.
- *
+ *
* @param f The manifest file.
* @throws IOException If a problem occurred while trying to read the manifest file.
*/
@@ -50,7 +50,7 @@ public class ManifestFile extends ObjectMap {
/**
* Create an instance of this class from a {@link Manifest} object.
- *
+ *
* @param f The manifest to read from.
*/
public ManifestFile(Manifest f) {
@@ -59,7 +59,7 @@ public class ManifestFile extends ObjectMap {
/**
* Finds and loads the manifest file of the jar file that the specified class is contained within.
- *
+ *
* @param c The class to get the manifest file of.
* @throws IOException If a problem occurred while trying to read the manifest file.
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MessageBundle.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MessageBundle.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MessageBundle.java
index 28df465..c529fc8 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MessageBundle.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MessageBundle.java
@@ -23,7 +23,7 @@ import org.apache.juneau.*;
/**
* Wraps a {@link ResourceBundle} to provide some useful additional functionality.
- *
+ *
* <ul class='spaced-list'>
* <li>
* Instead of throwing {@link MissingResourceException}, the {@link #getString(String)} method
@@ -47,10 +47,10 @@ import org.apache.juneau.*;
* the message can be retrieved using <code>getString(<js>"myMessage"</js>)</code>.
* </ul>
*
- * <h5 class='section'>Notes:</h5>
- * <ul>
- * <li>This class is thread-safe.
- * </ul>
+ * <h5 class='section'>Notes:</h5>
+ * <ul>
+ * <li>This class is thread-safe.
+ * </ul>
*/
public class MessageBundle extends ResourceBundle {
@@ -78,7 +78,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Sets the locale for this thread so that calls to {@link #getClientString(String, Object...)} return messages in
* that locale.
- *
+ *
* @param locale The new client locale.
*/
public static void setClientLocale(Locale locale) {
@@ -144,7 +144,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Constructor.
- *
+ *
* @param forClass The class using this resource bundle.
* @param bundlePath
* The path of the resource bundle to wrap.
@@ -197,14 +197,14 @@ public class MessageBundle extends ResourceBundle {
/**
* Add another bundle path to this resource bundle.
- *
+ *
* <p>
* Order of property lookup is first-to-last.
- *
+ *
* <p>
* This method must be called from the same thread as the call to the constructor.
* This eliminates the need for synchronization.
- *
+ *
* @param forClass The class using this resource bundle.
* @param bundlePath The bundle path.
* @return This object (for method chaining).
@@ -226,7 +226,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Similar to {@link ResourceBundle#getString(String)} except allows you to pass in {@link MessageFormat} objects.
- *
+ *
* @param key The resource bundle key.
* @param args Optional {@link MessageFormat}-style arguments.
* @return
@@ -243,7 +243,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Same as {@link #getString(String, Object...)} but allows you to specify the locale.
- *
+ *
* @param locale The locale of the resource bundle to retrieve message from.
* @param key The resource bundle key.
* @param args Optional {@link MessageFormat}-style arguments.
@@ -260,7 +260,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Same as {@link #getString(String, Object...)} but uses the locale specified on the call to {@link #setClientLocale(Locale)}.
- *
+ *
* @param key The resource bundle key.
* @param args Optional {@link MessageFormat}-style arguments.
* @return
@@ -274,7 +274,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Looks for all the specified keys in the resource bundle and returns the first value that exists.
- *
+ *
* @param keys The list of possible keys.
* @return The resolved value, or <jk>null</jk> if no value is found or the resource bundle is missing.
*/
@@ -290,7 +290,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Same as {@link #findFirstString(String...)}, but uses the specified locale.
- *
+ *
* @param locale The locale of the resource bundle to retrieve message from.
* @param keys The list of possible keys.
* @return The resolved value, or <jk>null</jk> if no value is found or the resource bundle is missing.
@@ -307,7 +307,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Returns all keys in this resource bundle with the specified prefix.
- *
+ *
* @param prefix The prefix.
* @return The set of all keys in the resource bundle with the prefix.
*/
@@ -348,15 +348,15 @@ public class MessageBundle extends ResourceBundle {
/**
* Returns this resource bundle as an {@link ObjectMap}.
- *
+ *
* <p>
* Useful for debugging purposes.
* Note that any class that implements a <code>swap()</code> method will automatically be serialized by
* calling this method and serializing the result.
- *
+ *
* <p>
* This method always constructs a new {@link ObjectMap} on each call.
- *
+ *
* @return A new map containing all the keys and values in this bundle.
*/
public ObjectMap swap() {
@@ -368,7 +368,7 @@ public class MessageBundle extends ResourceBundle {
/**
* Returns the resource bundle for the specified locale.
- *
+ *
* @param locale The client locale.
* @return The resource bundle for the specified locale. Never <jk>null</jk>.
*/
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MetadataMap.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MetadataMap.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MetadataMap.java
index 459f200..6535f82 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MetadataMap.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/MetadataMap.java
@@ -20,10 +20,10 @@ import org.apache.juneau.*;
/**
* Utility class for quick lookup of class metadata instances.
- *
+ *
* <p>
* Class instances are created once and then cached.
- *
+ *
* <p>
* Classes must have a constructor that takes in a single argument.
*/
@@ -35,7 +35,7 @@ public class MetadataMap {
/**
* Constructor.
- *
+ *
* @param c The metadata class to create.
* @param constructorArg The argument needed to construct the metadata.
* @return The cached metadata object.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoIntrospector.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoIntrospector.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoIntrospector.java
index 9683934..56f1770 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoIntrospector.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoIntrospector.java
@@ -21,7 +21,7 @@ import org.apache.juneau.parser.*;
/**
* Used to invoke methods on {@code Objects} using arguments in serialized form.
- *
+ *
* <h5 class='section'>Example:</h5>
* <p class='bcode'>
* String s = <js>"foobar"</js>;
@@ -36,7 +36,7 @@ public final class PojoIntrospector {
/**
* Constructor.
- *
+ *
* @param o The object on which Java methods will be invoked.
* @param p The parser to use to parse the method arguments.
* If <jk>null</jk>, {@link JsonParser#DEFAULT} is used.
@@ -50,7 +50,7 @@ public final class PojoIntrospector {
/**
* Shortcut for calling <code><jk>new</jk> PojoIntrospector(o, <jk>null</jk>);</code>
- *
+ *
* @param o The object on which Java methods will be invoked.
*/
public PojoIntrospector(Object o) {
@@ -59,7 +59,7 @@ public final class PojoIntrospector {
/**
* Primary method. Invokes the specified method on this bean.
- *
+ *
* @param method The method being invoked.
* @param args
* The arguments to pass as parameters to the method.
@@ -96,7 +96,7 @@ public final class PojoIntrospector {
/**
* Convenience method for invoking argument from method signature (@see {@link ClassUtils#getMethodSignature(Method)}.
- *
+ *
* @param method The method being invoked.
* @param args
* The arguments to pass as parameters to the method.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoMerge.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoMerge.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoMerge.java
index b967922..ae21934 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoMerge.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoMerge.java
@@ -16,53 +16,54 @@ import java.lang.reflect.*;
/**
* Utility class for merging POJOs behind a single interface.
- *
+ *
* <p>
* Useful in cases where you want to define beans with 'default' values.
- *
+ *
* <p>
* For example, given the following bean classes...
- *
+ *
* <p class='bcode'>
* <jk>public interface</jk> IA {
* String getX();
* <jk>void</jk> setX(String x);
* }
- *
+ *
* <jk>public class</jk> A <jk>implements</jk> IA {
* <jk>private</jk> String <jf>x</jf>;
- *
+ *
* <jk>public</jk> A(String x) {
* <jk>this</jk>.<jf>x</jf> = x;
* }
- *
+ *
* <jk>public</jk> String getX() {
* <jk>return</jk> <jf>x</jf>;
* }
- *
+ *
* <jk>public void</jk> setX(String x) {
* <jk>this</jk>.<jf>x</jf> = x;
* }
* }
* </p>
- *
+ *
* <p>
* The getters will be called in order until the first non-null value is returned...
- *
+ *
* <p class='bcode'>
* PojoMerge m;
- *
+ *
* m = PojoMerge.<jsm>merge</jsm>(IA.<jk>class</jk>, <jk>new</jk> A(<js>"1"</js>), <jk>new</jk> A(<js>"2"</js>));
* <jsm>assertEquals</jsm>(<js>"1"</js>, m.getX());
- *
+ *
* m = PojoMerge.<jsm>merge</jsm>(IA.<jk>class</jk>, <jk>new</jk> A(<jk>null</jk>), <jk>new</jk> A(<js>"2"</js>));
* <jsm>assertEquals</jsm>(<js>"2"</js>, m.getX());
- *
+ *
* m = PojoMerge.<jsm>merge</jsm>(IA.<jk>class</jk>, <jk>new</jk> A(<jk>null</jk>), <jk>new</jk> A(<jk>null</jk>));
* <jsm>assertEquals</jsm>(<jk>null</jk>, m.getX());
* </p>
- *
- * <h5 class='section'>Notes:</h5>
+ *
+ *
+ * <h5 class='topic'>Notes</h5>
* <ul>
* <li>Null POJOs are ignored.
* <li>Non-getter methods are either invoked on the first POJO or all POJOs depending on the <code>callAllNonGetters</code> flag
@@ -74,10 +75,10 @@ public class PojoMerge {
/**
* Create a proxy interface on top of zero or more POJOs.
- *
+ *
* <p>
* This is a shortcut to calling <code>merge(interfaceClass, <jk>false</jk>, pojos);</code>
- *
+ *
* @param interfaceClass The common interface class.
* @param pojos
* Zero or more POJOs to merge.
@@ -91,7 +92,7 @@ public class PojoMerge {
/**
* Create a proxy interface on top of zero or more POJOs.
- *
+ *
* @param interfaceClass The common interface class.
* @param callAllNonGetters
* If <jk>true</jk>, when calling a method that's not a getter, the method will be invoked on all POJOs.
http://git-wip-us.apache.org/repos/asf/juneau/blob/5686b8d6/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoQuery.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoQuery.java b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoQuery.java
index 3ff1666..912098c 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoQuery.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/utils/PojoQuery.java
@@ -25,10 +25,10 @@ import org.apache.juneau.internal.*;
/**
* Designed to provide search/view/sort/paging filtering on tabular in-memory POJO models.
- *
+ *
* <p>
* It can also perform just view filtering on beans/maps.
- *
+ *
* <p>
* Examples of tabular POJO models:
* <ul>
@@ -37,7 +37,7 @@ import org.apache.juneau.internal.*;
* <li><tt>Map[]</tt>
* <li><tt>Bean[]</tt>
* </ul>
- *
+ *
* <p>
* Tabular POJO models can be thought of as tables of data. For example, a list of the following beans...
* <p class='bcode'>
@@ -54,7 +54,7 @@ import org.apache.juneau.internal.*;
* <tr><td>123</td><td>'foobar'</td><td>yyyy/MM/dd HH:mm:ss</td></tr>
* <tr><td colspan=3>...</td></tr>
* </table>
- *
+ *
* <p>
* From this table, you can perform the following functions:
* <ul class='spaced-list'>
@@ -67,13 +67,14 @@ import org.apache.juneau.internal.*;
* <li>
* Position/limit - Only return a subset of rows.
* </ul>
- *
+ *
+ *
* <h5 class='topic'>Search</h5>
- *
+ *
* The search capabilities allow you to filter based on query patterns against strings, dates, and numbers.
* Queries take the form of a Map with column names as keys, and search patterns as values.
* <br>Multiple search patterns are ANDed (i.e. all patterns must match for the row to be returned).
- *
+ *
* <h5 class='section'>Example:</h5>
* <ul class='spaced-list'>
* <li>
@@ -83,13 +84,14 @@ import org.apache.juneau.internal.*;
* <li>
* <tt>{myDate:'2001'}</tt> - Return only rows where the <tt>myDate</tt> column have dates in the year 2001.
* </ul>
- *
+ *
+ *
* <h5 class='topic'>String Patterns</h5>
- *
+ *
* Any objects can be queried against using string patterns.
* If the objects being searched are not strings, then the patterns are matched against whatever is return by the
* {@code Object#toString()} method.
- *
+ *
* <h6 class='topic'>Example string query patterns:</h6>
* <ul>
* <li><tt>foo</tt> - The string 'foo'
@@ -99,7 +101,7 @@ import org.apache.juneau.internal.*;
* <li><tt>foo*</tt> - <tt>*</tt> matches zero-or-more characters.
* <li><tt>foo?</tt> - <tt>?</tt> matches exactly one character
* </ul>
- *
+ *
* <h5 class='section'>Notes:</h5>
* <ul class='spaced-list'>
* <li>
@@ -109,11 +111,12 @@ import org.apache.juneau.internal.*;
* <li>
* Prepend <tt>-</tt> to tokens that must not match. (e.g. <tt>+foo* -*bar</tt>)
* </ul>
- *
+ *
+ *
* <h5 class='topic'>Numeric Patterns</h5>
- *
+ *
* Any object of type {@link Number} (or numeric primitives) can be searched using numeric patterns.
- *
+ *
* <h6 class='topic'>Example numeric query patterns:</h6>
* <ul>
* <li><tt>123</tt> - The single number 123
@@ -125,7 +128,7 @@ import org.apache.juneau.internal.*;
* <li><tt>>= 100</tt> - Greater than or equal to 100
* <li><tt>!123</tt> - Not 123
* </ul>
- *
+ *
* <h5 class='section'>Notes:</h5>
* <ul class='spaced-list'>
* <li>
@@ -133,15 +136,16 @@ import org.apache.juneau.internal.*;
* <li>
* Negative numbers are supported.
* </ul>
- *
+ *
+ *
* <h5 class='topic'>Date Patterns</h5>
- *
+ *
* Any object of type {@link Date} or {@link Calendar} can be searched using date patterns.
- *
+ *
* <p>
* The default valid input timestamp formats (which can be overridden via the {@link #setValidTimestampFormats(String...)}
* method are...
- *
+ *
* <ul>
* <li><tt>yyyy.MM.dd.HH.mm.ss</tt>
* <li><tt>yyyy.MM.dd.HH.mm</tt>
@@ -150,7 +154,7 @@ import org.apache.juneau.internal.*;
* <li><tt>yyyy.MM</tt>
* <li><tt>yyyy</tt>
* </ul>
- *
+ *
* <h6 class='topic'>Example date query patterns:</h6>
* <ul>
* <li><tt>2001</tt> - A specific year.
@@ -160,29 +164,31 @@ import org.apache.juneau.internal.*;
* <li><tt>2001 - 2003.06.30</tt> - A date range.
* <li><tt>2001 2003 2005</tt> - Multiple date patterns are ORed.
* </ul>
- *
+ *
* <h5 class='section'>Notes:</h5>
* <ul>
* <li>Whitespace is ignored in search patterns.
* </ul>
- *
+ *
+ *
* <h5 class='topic'>View</h5>
- *
+ *
* The view capability allows you to return only the specified subset of columns in the specified order.
* <br>The view parameter is a list of either <tt>Strings</tt> or <tt>Maps</tt>.
- *
+ *
* <h6 class='topic'>Example view parameters:</h6>
* <ul>
* <li><tt>column1</tt> - Return only column 'column1'.
* <li><tt>column2, column1</tt> - Return only columns 'column2' and 'column1' in that order.
* </ul>
- *
+ *
+ *
* <h5 class='topic'>Sort</h5>
- *
+ *
* The sort capability allows you to sort values by the specified rows.
* <br>The sort parameter is a list of strings with an optional <js>'+'</js> or <js>'-'</js> suffix representing
* ascending and descending order accordingly.
- *
+ *
* <h6 class='topic'>Example sort parameters:</h6>
* <ul>
* <li><tt>column1</tt> - Sort rows by column 'column1' ascending.
@@ -190,9 +196,10 @@ import org.apache.juneau.internal.*;
* <li><tt>column1-</tt> - Sort rows by column 'column1' descending.
* <li><tt>column1, column2-</tt> - Sort rows by column 'column1' ascending, then 'column2' descending.
* </ul>
- *
+ *
+ *
* <h5 class='topic'>Paging</h5>
- *
+ *
* Use the <tt>position</tt> and <tt>limit</tt> parameters to specify a subset of rows to return.
*/
@SuppressWarnings({"unchecked","rawtypes"})
@@ -204,7 +211,7 @@ public final class PojoQuery {
/**
* Constructor.
- *
+ *
* @param input The POJO we're going to be filtering.
* @param session The bean session to use to create bean maps for beans.
*/
@@ -216,7 +223,7 @@ public final class PojoQuery {
/**
* Filters the input object as a collection of maps.
- *
+ *
* @param args The search arguments.
* @return The filtered collection.
* Returns the unaltered input if the input is not a collection or array of objects.
@@ -505,7 +512,7 @@ public final class PojoQuery {
/**
* Construct a number matcher for the given search pattern.
- *
+ *
* @param searchPattern A date search paattern. See class usage for a description.
*/
public NumberMatcher(String searchPattern) {
@@ -651,7 +658,7 @@ public final class PojoQuery {
/**
* Use this method to override the allowed search patterns when used in locales where time formats are different.
- *
+ *
* @param s A comma-delimited list of valid time formats.
*/
public void setValidTimestampFormats(String...s) {
@@ -666,7 +673,7 @@ public final class PojoQuery {
/**
* Construct a timestamp matcher for the given search pattern.
- *
+ *
* @param searchPattern The search pattern.
*/
DateMatcher(String searchPattern) {
@@ -677,7 +684,7 @@ public final class PojoQuery {
/**
* Returns <jk>true</jk> if the specified date matches the pattern passed in through the constructor.
- *
+ *
* <p>
* <br>The Object can be of type {@link Date} or {@link Calendar}.
* <br>Always returns <jk>false</jk> on <jk>null</jk> input.
@@ -851,7 +858,7 @@ public final class PojoQuery {
* Parses a timestamp string off the beginning of the string segment 'seg'.
* Goes through each possible valid timestamp format until it finds a match.
* The position where the parsing left off is stored in pp.
- *
+ *
* @param seg The string segment being parsed.
* @param pp Where parsing last left off.
* @return An object representing a timestamp.
@@ -919,7 +926,7 @@ public final class PojoQuery {
/**
* Construct a string matcher for the given search pattern.
- *
+ *
* @param searchPattern The search pattern. See class usage for details.
* @param ignoreCase If <jk>true</jk>, use case-insensitive matching.
*/
@@ -1132,7 +1139,7 @@ public final class PojoQuery {
/**
* Replaces tokens in a string with a different token.
- *
+ *
* <p>
* replace("A and B and C", "and", "or") -> "A or B or C"
* replace("andandand", "and", "or") -> "ororor"