--- old/src/java.xml/share/classes/javax/xml/datatype/DatatypeFactory.java 2015-04-21 18:33:54.720094845 +0400
+++ new/src/java.xml/share/classes/javax/xml/datatype/DatatypeFactory.java 2015-04-21 18:33:54.632094845 +0400
@@ -32,11 +32,10 @@
import java.util.regex.Pattern;
/**
- * Factory that creates new javax.xml.datatype
Object
s that map XML to/from Java Object
s.
+ * Factory that creates new {@code javax.xml.datatype} {@code Object}s that map XML to/from Java {@code Object}s.
*
* A new instance of the {@code DatatypeFactory} is created through the {@link #newInstance()} method * that uses the following implementation resolution mechanisms to determine an implementation: - *
*
Default property name as defined in JSR 206: Java(TM) API for XML Processing (JAXP) 1.3.
+ * Default property name as defined in JSR 206: Java(TM) API for XML Processing (JAXP) 1.3. * - *Default value is {@code javax.xml.datatype.DatatypeFactory}.
+ *Default value is {@code javax.xml.datatype.DatatypeFactory}. */ public static final String DATATYPEFACTORY_PROPERTY = // We use a String constant here, rather than calling @@ -100,16 +99,15 @@ "javax.xml.datatype.DatatypeFactory"; /** - *
Default implementation class name as defined in - * JSR 206: Java(TM) API for XML Processing (JAXP) 1.3.
+ * Default implementation class name as defined in + * JSR 206: Java(TM) API for XML Processing (JAXP) 1.3. * *Implementers should specify the name of an appropriate class * to be instantiated if no other implementation resolution mechanism - * succeeds.
+ * succeeds. * *Users should not refer to this field; it is intended only to * document a factory implementation detail. - *
*/ public static final String DATATYPEFACTORY_IMPLEMENTATION_CLASS = // We use new String() here to prevent javadoc from generating @@ -130,18 +128,18 @@ Pattern.compile("[^YM]*[DT].*"); /** - *Protected constructor to prevent instantiation outside of package.
+ * Protected constructor to prevent instantiation outside of package. * - *Use {@link #newInstance()} to create a {@code DatatypeFactory}.
+ *Use {@link #newInstance()} to create a {@code DatatypeFactory}. */ protected DatatypeFactory() { } /** - *
Obtain a new instance of a {@code DatatypeFactory}.
+ * Obtain a new instance of a {@code DatatypeFactory}. * *The implementation resolution mechanisms are defined in this
- * Class
's documentation.
Obtain a new instance of a {@code DatatypeFactory} from class name. + * Obtain a new instance of a {@code DatatypeFactory} from class name. * This function is useful when there are multiple providers in the classpath. * It gives more control to the application as it can specify which provider - * should be loaded.
+ * should be loaded. * *Once an application has obtained a reference to a {@code DatatypeFactory} - * it can use the factory to configure and obtain datatype instances.
+ * it can use the factory to configure and obtain datatype instances. * * *Setting the jaxp.debug
system property will cause
+ *
Setting the {@code jaxp.debug} system property will cause
* this method to print a lot of debug messages
- * to System.err
about what it is doing and where it is looking at.
If you have problems try:
+ *If you have problems try: *
* java -Djaxp.debug=1 YourProgram .... ** * @param factoryClassName fully qualified factory class name that provides implementation of {@code javax.xml.datatype.DatatypeFactory}. * - * @param classLoader
ClassLoader
used to load the factory class. If null
- * current Thread
's context classLoader is used to load the factory class.
+ * @param classLoader {@code ClassLoader} used to load the factory class. If {@code null}
+ * current {@code Thread}'s context classLoader is used to load the factory class.
*
* @return New instance of a {@code DatatypeFactory}
*
- * @throws DatatypeConfigurationException if factoryClassName
is null
, or
+ * @throws DatatypeConfigurationException if {@code factoryClassName} is {@code null}, or
* the factory class cannot be loaded, instantiated.
*
* @see #newInstance()
@@ -201,11 +199,11 @@
}
/**
- * Obtain a new instance of a Duration
- * specifying the Duration
as its string representation, "PnYnMnDTnHnMnS",
- * as defined in XML Schema 1.0 section 3.2.6.1.
XML Schema Part 2: Datatypes, 3.2.6 duration, defines duration
as:
XML Schema Part 2: Datatypes, 3.2.6 duration, defines {@code duration} as: *
* duration represents a duration of time. * The value space of duration is a six-dimensional space where the coordinates designate the @@ -213,28 +211,28 @@ * These components are ordered in their significance by their order of appearance i.e. as * year, month, day, hour, minute, and second. *- *
All six values are set and available from the created {@link Duration}
+ *All six values are set and available from the created {@link Duration} * *
The XML Schema specification states that values can be of an arbitrary size. * Implementations may chose not to or be incapable of supporting arbitrarily large and/or small values. * An {@link UnsupportedOperationException} will be thrown with a message indicating implementation limits - * if implementation capacities are exceeded.
+ * if implementation capacities are exceeded. * - * @param lexicalRepresentationString
representation of a Duration
.
+ * @param lexicalRepresentation {@code String} representation of a {@code Duration}.
*
- * @return New Duration
created from parsing the lexicalRepresentation
.
+ * @return New {@code Duration} created from parsing the {@code lexicalRepresentation}.
*
- * @throws IllegalArgumentException If lexicalRepresentation
is not a valid representation of a Duration
.
+ * @throws IllegalArgumentException If {@code lexicalRepresentation} is not a valid representation of a {@code Duration}.
* @throws UnsupportedOperationException If implementation cannot support requested values.
- * @throws NullPointerException if lexicalRepresentation
is null
.
+ * @throws NullPointerException if {@code lexicalRepresentation} is {@code null}.
*/
public abstract Duration newDuration(final String lexicalRepresentation);
/**
- * Obtain a new instance of a Duration
- * specifying the Duration
as milliseconds.
XML Schema Part 2: Datatypes, 3.2.6 duration, defines duration
as:
XML Schema Part 2: Datatypes, 3.2.6 duration, defines {@code duration} as: *
* duration represents a duration of time. * The value space of duration is a six-dimensional space where the coordinates designate the @@ -243,8 +241,8 @@ * year, month, day, hour, minute, and second. **
All six values are set by computing their values from the specified milliseconds
- * and are available using the get
methods of the created {@link Duration}.
- * The values conform to and are defined by:
Duration
representing durationInMilliSeconds
.
+ * @return New {@code Duration} representing {@code durationInMilliSeconds}.
*/
public abstract Duration newDuration(final long durationInMilliSeconds);
/**
- * Obtain a new instance of a Duration
- * specifying the Duration
as isPositive, years, months, days, hours, minutes, seconds.
The XML Schema specification states that values can be of an arbitrary size. * Implementations may chose not to or be incapable of supporting arbitrarily large and/or small values. * An {@link UnsupportedOperationException} will be thrown with a message indicating implementation limits - * if implementation capacities are exceeded.
+ * if implementation capacities are exceeded. * - *A null
value indicates that field is not set.
A {@code null} value indicates that field is not set.
*
- * @param isPositive Set to false
to create a negative duration. When the length
+ * @param isPositive Set to {@code false} to create a negative duration. When the length
* of the duration is zero, this parameter will be ignored.
- * @param years of this Duration
- * @param months of this Duration
- * @param days of this Duration
- * @param hours of this Duration
- * @param minutes of this Duration
- * @param seconds of this Duration
+ * @param years of this {@code Duration}
+ * @param months of this {@code Duration}
+ * @param days of this {@code Duration}
+ * @param hours of this {@code Duration}
+ * @param minutes of this {@code Duration}
+ * @param seconds of this {@code Duration}
*
- * @return New Duration
created from the specified values.
+ * @return New {@code Duration} created from the specified values.
*
* @throws IllegalArgumentException If the values are not a valid representation of a
- * Duration
: if all the fields (years, months, ...) are null or
+ * {@code Duration}: if all the fields (years, months, ...) are null or
* if any of the fields is negative.
* @throws UnsupportedOperationException If implementation cannot support requested values.
*/
@@ -304,24 +302,24 @@
final BigDecimal seconds);
/**
- *
Obtain a new instance of a Duration
- * specifying the Duration
as isPositive, years, months, days, hours, minutes, seconds.
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
*
- * @param isPositive Set to false
to create a negative duration. When the length
+ * @param isPositive Set to {@code false} to create a negative duration. When the length
* of the duration is zero, this parameter will be ignored.
- * @param years of this Duration
- * @param months of this Duration
- * @param days of this Duration
- * @param hours of this Duration
- * @param minutes of this Duration
- * @param seconds of this Duration
+ * @param years of this {@code Duration}
+ * @param months of this {@code Duration}
+ * @param days of this {@code Duration}
+ * @param hours of this {@code Duration}
+ * @param minutes of this {@code Duration}
+ * @param seconds of this {@code Duration}
*
- * @return New Duration
created from the specified values.
+ * @return New {@code Duration} created from the specified values.
*
* @throws IllegalArgumentException If the values are not a valid representation of a
- * Duration
: if any of the fields is negative.
+ * {@code Duration}: if any of the fields is negative.
*
* @see #newDuration(
* boolean isPositive,
@@ -371,28 +369,30 @@
}
/**
- *
Create a Duration
of type xdt:dayTimeDuration
by parsing its String
representation,
+ * Create a {@code Duration} of type {@code xdt:dayTimeDuration}
+ * by parsing its {@code String} representation,
* "PnDTnHnMnS",
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:dayTimeDuration.
The datatype xdt:dayTimeDuration
is a subtype of xs:duration
+ *
The datatype {@code xdt:dayTimeDuration} is a subtype of {@code xs:duration}
* whose lexical representation contains only day, hour, minute, and second components.
- * This datatype resides in the namespace http://www.w3.org/2003/11/xpath-datatypes
.
All four values are set and available from the created {@link Duration}
+ *All four values are set and available from the created {@link Duration} * *
The XML Schema specification states that values can be of an arbitrary size. * Implementations may chose not to or be incapable of supporting arbitrarily large and/or small values. * An {@link UnsupportedOperationException} will be thrown with a message indicating implementation limits - * if implementation capacities are exceeded.
+ * if implementation capacities are exceeded. * * @param lexicalRepresentation Lexical representation of a duration. * - * @return NewDuration
created using the specified lexicalRepresentation
.
+ * @return New {@code Duration} created using the specified {@code lexicalRepresentation}.
*
- * @throws IllegalArgumentException If lexicalRepresentation
is not a valid representation of a Duration
expressed only in terms of days and time.
+ * @throws IllegalArgumentException If {@code lexicalRepresentation} is
+ * not a valid representation of a {@code Duration} expressed only in terms of days and time.
* @throws UnsupportedOperationException If implementation cannot support requested values.
- * @throws NullPointerException If lexicalRepresentation
is null
.
+ * @throws NullPointerException If {@code lexicalRepresentation} is {@code null}.
*/
public Duration newDurationDayTime(final String lexicalRepresentation) {
// lexicalRepresentation must be non-null
@@ -415,17 +415,18 @@
}
/**
- * Create a Duration
of type xdt:dayTimeDuration
using the specified milliseconds as defined in
+ * Create a {@code Duration} of type {@code xdt:dayTimeDuration}
+ * using the specified milliseconds as defined in
*
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:dayTimeDuration.
The datatype xdt:dayTimeDuration
is a subtype of xs:duration
+ *
The datatype {@code xdt:dayTimeDuration} is a subtype of {@code xs:duration}
* whose lexical representation contains only day, hour, minute, and second components.
- * This datatype resides in the namespace http://www.w3.org/2003/11/xpath-datatypes
.
All four values are set by computing their values from the specified milliseconds
- * and are available using the get
methods of the created {@link Duration}.
- * The values conform to and are defined by:
Any remaining milliseconds after determining the day, hour, minute and second are discarded.
+ *Any remaining milliseconds after determining the day, hour, minute and second are discarded.
*
- * @param durationInMilliseconds Milliseconds of Duration
to create.
+ * @param durationInMilliseconds Milliseconds of {@code Duration} to create.
*
- * @return New Duration
created with the specified durationInMilliseconds
.
+ * @return New {@code Duration} created with the specified {@code durationInMilliseconds}.
*
* @see
* XQuery 1.0 and XPath 2.0 Data Model, xdt:dayTimeDuration
@@ -457,34 +458,34 @@
}
/**
- *
Create a Duration
of type xdt:dayTimeDuration
using the specified
- * day
, hour
, minute
and second
as defined in
+ * Create a {@code Duration} of type {@code xdt:dayTimeDuration} using the specified
+ * {@code day}, {@code hour}, {@code minute} and {@code second} as defined in
*
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:dayTimeDuration.
The datatype xdt:dayTimeDuration
is a subtype of xs:duration
+ *
The datatype {@code xdt:dayTimeDuration} is a subtype of {@code xs:duration}
* whose lexical representation contains only day, hour, minute, and second components.
- * This datatype resides in the namespace http://www.w3.org/2003/11/xpath-datatypes
.
The XML Schema specification states that values can be of an arbitrary size. * Implementations may chose not to or be incapable of supporting arbitrarily large and/or small values. * An {@link UnsupportedOperationException} will be thrown with a message indicating implementation limits - * if implementation capacities are exceeded.
+ * if implementation capacities are exceeded. * - *A null
value indicates that field is not set.
A {@code null} value indicates that field is not set.
*
- * @param isPositive Set to false
to create a negative duration. When the length
+ * @param isPositive Set to {@code false} to create a negative duration. When the length
* of the duration is zero, this parameter will be ignored.
- * @param day Day of Duration
.
- * @param hour Hour of Duration
.
- * @param minute Minute of Duration
.
- * @param second Second of Duration
.
+ * @param day Day of {@code Duration}.
+ * @param hour Hour of {@code Duration}.
+ * @param minute Minute of {@code Duration}.
+ * @param second Second of {@code Duration}.
*
- * @return New Duration
created with the specified day
, hour
, minute
- * and second
.
+ * @return New {@code Duration} created with the specified {@code day}, {@code hour}, {@code minute}
+ * and {@code second}.
*
* @throws IllegalArgumentException If the values are not a valid representation of a
- * Duration
: if all the fields (day, hour, ...) are null or
+ * {@code Duration}: if all the fields (day, hour, ...) are null or
* if any of the fields is negative.
* @throws UnsupportedOperationException If implementation cannot support requested values.
*/
@@ -507,29 +508,29 @@
}
/**
- *
Create a Duration
of type xdt:dayTimeDuration
using the specified
- * day
, hour
, minute
and second
as defined in
+ * Create a {@code Duration} of type {@code xdt:dayTimeDuration} using the specified
+ * {@code day}, {@code hour}, {@code minute} and {@code second} as defined in
*
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:dayTimeDuration.
The datatype xdt:dayTimeDuration
is a subtype of xs:duration
+ *
The datatype {@code xdt:dayTimeDuration} is a subtype of {@code xs:duration}
* whose lexical representation contains only day, hour, minute, and second components.
- * This datatype resides in the namespace http://www.w3.org/2003/11/xpath-datatypes
.
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
*
- * @param isPositive Set to false
to create a negative duration. When the length
+ * @param isPositive Set to {@code false} to create a negative duration. When the length
* of the duration is zero, this parameter will be ignored.
- * @param day Day of Duration
.
- * @param hour Hour of Duration
.
- * @param minute Minute of Duration
.
- * @param second Second of Duration
.
+ * @param day Day of {@code Duration}.
+ * @param hour Hour of {@code Duration}.
+ * @param minute Minute of {@code Duration}.
+ * @param second Second of {@code Duration}.
*
- * @return New Duration
created with the specified day
, hour
, minute
- * and second
.
+ * @return New {@code Duration} created with the specified {@code day}, {@code hour}, {@code minute}
+ * and {@code second}.
*
* @throws IllegalArgumentException If the values are not a valid representation of a
- * Duration
: if any of the fields (day, hour, ...) is negative.
+ * {@code Duration}: if any of the fields (day, hour, ...) is negative.
*/
public Duration newDurationDayTime(
final boolean isPositive,
@@ -548,28 +549,30 @@
}
/**
- *
Create a Duration
of type xdt:yearMonthDuration
by parsing its String
representation,
+ * Create a {@code Duration} of type {@code xdt:yearMonthDuration}
+ * by parsing its {@code String} representation,
* "PnYnM",
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:yearMonthDuration.
The datatype xdt:yearMonthDuration
is a subtype of xs:duration
+ *
The datatype {@code xdt:yearMonthDuration} is a subtype of {@code xs:duration} * whose lexical representation contains only year and month components. - * This datatype resides in the namespace {@link javax.xml.XMLConstants#W3C_XPATH_DATATYPE_NS_URI}.
+ * This datatype resides in the namespace {@link javax.xml.XMLConstants#W3C_XPATH_DATATYPE_NS_URI}. * - *Both values are set and available from the created {@link Duration}
+ *Both values are set and available from the created {@link Duration} * *
The XML Schema specification states that values can be of an arbitrary size. - * Implementations may chose not to or be incapable of supporting arbitrarily large and/or small values. - * An {@link UnsupportedOperationException} will be thrown with a message indicating implementation limits - * if implementation capacities are exceeded.
+ * Implementations may chose not to or be incapable of supporting + * arbitrarily large and/or small values. An {@link UnsupportedOperationException} + * will be thrown with a message indicating implementation limits + * if implementation capacities are exceeded. * * @param lexicalRepresentation Lexical representation of a duration. * - * @return NewDuration
created using the specified lexicalRepresentation
.
+ * @return New {@code Duration} created using the specified {@code lexicalRepresentation}.
*
- * @throws IllegalArgumentException If lexicalRepresentation
is not a valid representation of a Duration
expressed only in terms of years and months.
+ * @throws IllegalArgumentException If {@code lexicalRepresentation} is not a valid representation of a {@code Duration} expressed only in terms of years and months.
* @throws UnsupportedOperationException If implementation cannot support requested values.
- * @throws NullPointerException If lexicalRepresentation
is null
.
+ * @throws NullPointerException If {@code lexicalRepresentation} is {@code null}.
*/
public Duration newDurationYearMonth(
final String lexicalRepresentation) {
@@ -594,17 +597,18 @@
}
/**
- * Create a Duration
of type xdt:yearMonthDuration
using the specified milliseconds as defined in
+ * Create a {@code Duration} of type {@code xdt:yearMonthDuration}
+ * using the specified milliseconds as defined in
*
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:yearMonthDuration.
The datatype xdt:yearMonthDuration
is a subtype of xs:duration
+ *
The datatype {@code xdt:yearMonthDuration} is a subtype of {@code xs:duration} * whose lexical representation contains only year and month components. - * This datatype resides in the namespace {@link javax.xml.XMLConstants#W3C_XPATH_DATATYPE_NS_URI}.
+ * This datatype resides in the namespace {@link javax.xml.XMLConstants#W3C_XPATH_DATATYPE_NS_URI}. * *Both values are set by computing their values from the specified milliseconds
- * and are available using the get
methods of the created {@link Duration}.
- * The values conform to and are defined by:
Any remaining milliseconds after determining the year and month are discarded.
+ *Any remaining milliseconds after determining the year and month are discarded.
*
- * @param durationInMilliseconds Milliseconds of Duration
to create.
+ * @param durationInMilliseconds Milliseconds of {@code Duration} to create.
*
- * @return New Duration
created using the specified durationInMilliseconds
.
+ * @return New {@code Duration} created using the specified {@code durationInMilliseconds}.
*/
public Duration newDurationYearMonth(
final long durationInMilliseconds) {
@@ -646,27 +650,27 @@
}
/**
- *
Create a Duration
of type xdt:yearMonthDuration
using the specified
- * year
and month
as defined in
+ * Create a {@code Duration} of type {@code xdt:yearMonthDuration} using the specified
+ * {@code year} and {@code month} as defined in
*
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:yearMonthDuration.
The XML Schema specification states that values can be of an arbitrary size. * Implementations may chose not to or be incapable of supporting arbitrarily large and/or small values. * An {@link UnsupportedOperationException} will be thrown with a message indicating implementation limits - * if implementation capacities are exceeded.
+ * if implementation capacities are exceeded. * - *A null
value indicates that field is not set.
A {@code null} value indicates that field is not set.
*
- * @param isPositive Set to false
to create a negative duration. When the length
+ * @param isPositive Set to {@code false} to create a negative duration. When the length
* of the duration is zero, this parameter will be ignored.
- * @param year Year of Duration
.
- * @param month Month of Duration
.
+ * @param year Year of {@code Duration}.
+ * @param month Month of {@code Duration}.
*
- * @return New Duration
created using the specified year
and month
.
+ * @return New {@code Duration} created using the specified {@code year} and {@code month}.
*
* @throws IllegalArgumentException If the values are not a valid representation of a
- * Duration
: if all of the fields (year, month) are null or
+ * {@code Duration}: if all of the fields (year, month) are null or
* if any of the fields is negative.
* @throws UnsupportedOperationException If implementation cannot support requested values.
*/
@@ -687,22 +691,22 @@
}
/**
- *
Create a Duration
of type xdt:yearMonthDuration
using the specified
- * year
and month
as defined in
+ * Create a {@code Duration} of type {@code xdt:yearMonthDuration} using the specified
+ * {@code year} and {@code month} as defined in
*
- * XQuery 1.0 and XPath 2.0 Data Model, xdt:yearMonthDuration.
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
*
- * @param isPositive Set to false
to create a negative duration. When the length
+ * @param isPositive Set to {@code false} to create a negative duration. When the length
* of the duration is zero, this parameter will be ignored.
- * @param year Year of Duration
.
- * @param month Month of Duration
.
+ * @param year Year of {@code Duration}.
+ * @param month Month of {@code Duration}.
*
- * @return New Duration
created using the specified year
and month
.
+ * @return New {@code Duration} created using the specified {@code year} and {@code month}.
*
* @throws IllegalArgumentException If the values are not a valid representation of a
- * Duration
: if any of the fields (year, month) is negative.
+ * {@code Duration}: if any of the fields (year, month) is negative.
*/
public Duration newDurationYearMonth(
final boolean isPositive,
@@ -716,44 +720,44 @@
}
/**
- *
Create a new instance of an XMLGregorianCalendar
.
All date/time datatype fields set to {@link DatatypeConstants#FIELD_UNDEFINED} or null.
+ *All date/time datatype fields set to {@link DatatypeConstants#FIELD_UNDEFINED} or null.
*
- * @return New XMLGregorianCalendar
with all date/time datatype fields set to
+ * @return New {@code XMLGregorianCalendar} with all date/time datatype fields set to
* {@link DatatypeConstants#FIELD_UNDEFINED} or null.
*/
public abstract XMLGregorianCalendar newXMLGregorianCalendar();
/**
- *
Create a new XMLGregorianCalendar by parsing the String as a lexical representation.
+ * Create a new XMLGregorianCalendar by parsing the String as a lexical representation. * *Parsing the lexical string representation is defined in * XML Schema 1.0 Part 2, Section 3.2.[7-14].1, - * Lexical Representation.
+ * Lexical Representation. * - *The string representation may not have any leading and trailing whitespaces.
+ *The string representation may not have any leading and trailing whitespaces. * *
The parsing is done field by field so that - * the following holds for any lexically correct String x:
+ * the following holds for any lexically correct String x: ** newXMLGregorianCalendar(x).toXMLFormat().equals(x) **
Except for the noted lexical/canonical representation mismatches * listed in - * XML Schema 1.0 errata, Section 3.2.7.2.
+ * XML Schema 1.0 errata, Section 3.2.7.2. * * @param lexicalRepresentation Lexical representation of one the eight XML Schema date/time datatypes. * - * @returnXMLGregorianCalendar
created from the lexicalRepresentation
.
+ * @return {@code XMLGregorianCalendar} created from the {@code lexicalRepresentation}.
*
- * @throws IllegalArgumentException If the lexicalRepresentation
is not a valid XMLGregorianCalendar
.
- * @throws NullPointerException If lexicalRepresentation
is null
.
+ * @throws IllegalArgumentException If the {@code lexicalRepresentation} is not a valid {@code XMLGregorianCalendar}.
+ * @throws NullPointerException If {@code lexicalRepresentation} is {@code null}.
*/
public abstract XMLGregorianCalendar newXMLGregorianCalendar(final String lexicalRepresentation);
/**
- * Create an XMLGregorianCalendar
from a {@link GregorianCalendar}.
java.util.GregorianCalendar field |
- * javax.xml.datatype.XMLGregorianCalendar field |
+ * {@code java.util.GregorianCalendar} field | + *{@code javax.xml.datatype.XMLGregorianCalendar} field | *
---|---|---|---|
ERA == GregorianCalendar.BC ? -YEAR : YEAR |
+ * {@code ERA == GregorianCalendar.BC ? -YEAR : YEAR} | *{@link XMLGregorianCalendar#setYear(int year)} | *|
MONTH + 1 |
+ * {@code MONTH + 1} | *{@link XMLGregorianCalendar#setMonth(int month)} | *|
DAY_OF_MONTH |
+ * {@code DAY_OF_MONTH} | *{@link XMLGregorianCalendar#setDay(int day)} | *|
HOUR_OF_DAY, MINUTE, SECOND, MILLISECOND |
+ * {@code HOUR_OF_DAY, MINUTE, SECOND, MILLISECOND} | *{@link XMLGregorianCalendar#setTime(int hour, int minute, int second, BigDecimal fractional)} | *|
- * (ZONE_OFFSET + DST_OFFSET) / (60*1000) + * {@code (ZONE_OFFSET + DST_OFFSET) / (60*1000)} * (in minutes) * |
* {@link XMLGregorianCalendar#setTimezone(int offset)}* @@ -796,49 +800,50 @@ * |
*conversion loss of information. It is not possible to represent
- * a java.util.GregorianCalendar
daylight savings timezone id in the
- * XML Schema 1.0 date/time datatype representation.
To compute the return value's TimeZone
field,
+ *
To compute the return value's {@code TimeZone} field, *
this.getTimezone() != FIELD_UNDEFINED
,
- * create a java.util.TimeZone
with a custom timezone id
- * using the this.getTimezone()
.GregorianCalendar
default timezone value
+ * java.util.TimeZone.getDefault()
.java.util.GregorianCalendar
used to create XMLGregorianCalendar
+ * @param cal {@code java.util.GregorianCalendar} used to create {@code XMLGregorianCalendar}
*
- * @return XMLGregorianCalendar
created from java.util.GregorianCalendar
+ * @return {@code XMLGregorianCalendar} created from {@code java.util.GregorianCalendar}
*
- * @throws NullPointerException If cal
is null
.
+ * @throws NullPointerException If {@code cal} is {@code null}.
*/
public abstract XMLGregorianCalendar newXMLGregorianCalendar(final GregorianCalendar cal);
/**
- * Constructor allowing for complete value spaces allowed by
+ * Constructor allowing for complete value spaces allowed by
* W3C XML Schema 1.0 recommendation for xsd:dateTime and related
- * builtin datatypes. Note that year
parameter supports
+ * builtin datatypes. Note that {@code year} parameter supports
* arbitrarily large numbers and fractionalSecond has infinite
- * precision.
A null
value indicates that field is not set.
A {@code null} value indicates that field is not set.
*
- * @param year of XMLGregorianCalendar
to be created.
- * @param month of XMLGregorianCalendar
to be created.
- * @param day of XMLGregorianCalendar
to be created.
- * @param hour of XMLGregorianCalendar
to be created.
- * @param minute of XMLGregorianCalendar
to be created.
- * @param second of XMLGregorianCalendar
to be created.
- * @param fractionalSecond of XMLGregorianCalendar
to be created.
- * @param timezone of XMLGregorianCalendar
to be created.
+ * @param year of {@code XMLGregorianCalendar} to be created.
+ * @param month of {@code XMLGregorianCalendar} to be created.
+ * @param day of {@code XMLGregorianCalendar} to be created.
+ * @param hour of {@code XMLGregorianCalendar} to be created.
+ * @param minute of {@code XMLGregorianCalendar} to be created.
+ * @param second of {@code XMLGregorianCalendar} to be created.
+ * @param fractionalSecond of {@code XMLGregorianCalendar} to be created.
+ * @param timezone of {@code XMLGregorianCalendar} to be created.
*
- * @return XMLGregorianCalendar
created from specified values.
+ * @return {@code XMLGregorianCalendar} created from specified values.
*
* @throws IllegalArgumentException If any individual parameter's value is outside the maximum value constraint for the field
* as determined by the Date/Time Data Mapping table in {@link XMLGregorianCalendar}
- * or if the composite values constitute an invalid XMLGregorianCalendar
instance
+ * or if the composite values constitute an invalid {@code XMLGregorianCalendar} instance
* as determined by {@link XMLGregorianCalendar#isValid()}.
*/
public abstract XMLGregorianCalendar newXMLGregorianCalendar(
@@ -852,29 +857,29 @@
final int timezone);
/**
- *
Constructor of value spaces that a
- * java.util.GregorianCalendar
instance would need to convert to an
- * XMLGregorianCalendar
instance.
XMLGregorianCalendar eon
and
- * fractionalSecond
are set to null
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
- * - * @param year ofXMLGregorianCalendar
to be created.
- * @param month of XMLGregorianCalendar
to be created.
- * @param day of XMLGregorianCalendar
to be created.
- * @param hour of XMLGregorianCalendar
to be created.
- * @param minute of XMLGregorianCalendar
to be created.
- * @param second of XMLGregorianCalendar
to be created.
- * @param millisecond of XMLGregorianCalendar
to be created.
- * @param timezone of XMLGregorianCalendar
to be created.
+ * Constructor of value spaces that a
+ * {@code java.util.GregorianCalendar} instance would need to convert to an
+ * {@code XMLGregorianCalendar} instance.
+ *
+ * {@code XMLGregorianCalendar eon} and + * {@code fractionalSecond} are set to {@code null} + * + *
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *
+ * @param year of {@code XMLGregorianCalendar} to be created.
+ * @param month of {@code XMLGregorianCalendar} to be created.
+ * @param day of {@code XMLGregorianCalendar} to be created.
+ * @param hour of {@code XMLGregorianCalendar} to be created.
+ * @param minute of {@code XMLGregorianCalendar} to be created.
+ * @param second of {@code XMLGregorianCalendar} to be created.
+ * @param millisecond of {@code XMLGregorianCalendar} to be created.
+ * @param timezone of {@code XMLGregorianCalendar} to be created.
*
- * @return XMLGregorianCalendar
created from specified values.
+ * @return {@code XMLGregorianCalendar} created from specified values.
*
* @throws IllegalArgumentException If any individual parameter's value is outside the maximum value constraint for the field
* as determined by the Date/Time Data Mapping table in {@link XMLGregorianCalendar}
- * or if the composite values constitute an invalid XMLGregorianCalendar
instance
+ * or if the composite values constitute an invalid {@code XMLGregorianCalendar} instance
* as determined by {@link XMLGregorianCalendar#isValid()}.
*/
public XMLGregorianCalendar newXMLGregorianCalendar(
@@ -918,26 +923,26 @@
}
/**
- *
Create a Java representation of XML Schema builtin datatype date
or g*
.
For example, an instance of gYear
can be created invoking this factory
- * with month
and day
parameters set to
- * {@link DatatypeConstants#FIELD_UNDEFINED}.
For example, an instance of {@code gYear} can be created invoking this factory + * with {@code month} and {@code day} parameters set to + * {@link DatatypeConstants#FIELD_UNDEFINED}. * - *
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
*
- * @param year of XMLGregorianCalendar
to be created.
- * @param month of XMLGregorianCalendar
to be created.
- * @param day of XMLGregorianCalendar
to be created.
+ * @param year of {@code XMLGregorianCalendar} to be created.
+ * @param month of {@code XMLGregorianCalendar} to be created.
+ * @param day of {@code XMLGregorianCalendar} to be created.
* @param timezone offset in minutes. {@link DatatypeConstants#FIELD_UNDEFINED} indicates optional field is not set.
*
- * @return XMLGregorianCalendar
created from parameter values.
+ * @return {@code XMLGregorianCalendar} created from parameter values.
*
* @see DatatypeConstants#FIELD_UNDEFINED
*
* @throws IllegalArgumentException If any individual parameter's value is outside the maximum value constraint for the field
* as determined by the Date/Time Data Mapping table in {@link XMLGregorianCalendar}
- * or if the composite values constitute an invalid XMLGregorianCalendar
instance
+ * or if the composite values constitute an invalid {@code XMLGregorianCalendar} instance
* as determined by {@link XMLGregorianCalendar#isValid()}.
*/
public XMLGregorianCalendar newXMLGregorianCalendarDate(
@@ -958,20 +963,20 @@
}
/**
- *
Create a Java instance of XML Schema builtin datatype time
.
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
*
* @param hours number of hours
* @param minutes number of minutes
* @param seconds number of seconds
* @param timezone offset in minutes. {@link DatatypeConstants#FIELD_UNDEFINED} indicates optional field is not set.
*
- * @return XMLGregorianCalendar
created from parameter values.
+ * @return {@code XMLGregorianCalendar} created from parameter values.
*
* @throws IllegalArgumentException If any individual parameter's value is outside the maximum value constraint for the field
* as determined by the Date/Time Data Mapping table in {@link XMLGregorianCalendar}
- * or if the composite values constitute an invalid XMLGregorianCalendar
instance
+ * or if the composite values constitute an invalid {@code XMLGregorianCalendar} instance
* as determined by {@link XMLGregorianCalendar#isValid()}.
*
* @see DatatypeConstants#FIELD_UNDEFINED
@@ -994,24 +999,24 @@
}
/**
- *
Create a Java instance of XML Schema builtin datatype time.
+ * Create a Java instance of XML Schema builtin datatype time. * - *A null
value indicates that field is not set.
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *A {@code null} value indicates that field is not set. + *
A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
*
* @param hours number of hours
* @param minutes number of minutes
* @param seconds number of seconds
- * @param fractionalSecond value of null
indicates that this optional field is not set.
+ * @param fractionalSecond value of {@code null} indicates that this optional field is not set.
* @param timezone offset in minutes. {@link DatatypeConstants#FIELD_UNDEFINED} indicates optional field is not set.
*
- * @return XMLGregorianCalendar
created from parameter values.
+ * @return {@code XMLGregorianCalendar} created from parameter values.
*
* @see DatatypeConstants#FIELD_UNDEFINED
*
* @throws IllegalArgumentException If any individual parameter's value is outside the maximum value constraint for the field
* as determined by the Date/Time Data Mapping table in {@link XMLGregorianCalendar}
- * or if the composite values constitute an invalid XMLGregorianCalendar
instance
+ * or if the composite values constitute an invalid {@code XMLGregorianCalendar} instance
* as determined by {@link XMLGregorianCalendar#isValid()}.
*/
public XMLGregorianCalendar newXMLGregorianCalendarTime(
@@ -1033,9 +1038,9 @@
}
/**
- *
Create a Java instance of XML Schema builtin datatype time.
+ * Create a Java instance of XML Schema builtin datatype time. * - *A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
+ *A {@link DatatypeConstants#FIELD_UNDEFINED} value indicates that field is not set.
*
* @param hours number of hours
* @param minutes number of minutes
@@ -1043,13 +1048,13 @@
* @param milliseconds number of milliseconds
* @param timezone offset in minutes. {@link DatatypeConstants#FIELD_UNDEFINED} indicates optional field is not set.
*
- * @return XMLGregorianCalendar
created from parameter values.
+ * @return {@code XMLGregorianCalendar} created from parameter values.
*
* @see DatatypeConstants#FIELD_UNDEFINED
*
* @throws IllegalArgumentException If any individual parameter's value is outside the maximum value constraint for the field
* as determined by the Date/Time Data Mapping table in {@link XMLGregorianCalendar}
- * or if the composite values constitute an invalid XMLGregorianCalendar
instance
+ * or if the composite values constitute an invalid {@code XMLGregorianCalendar} instance
* as determined by {@link XMLGregorianCalendar#isValid()}.
*/
public XMLGregorianCalendar newXMLGregorianCalendarTime(