/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range */ public long computeMillis() { return computeMillis(false, (CharSequence) null); }
/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @param resetFields false by default, but when true, unsaved field values are cleared * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range */ public long computeMillis(boolean resetFields) { return computeMillis(resetFields, (CharSequence) null); }
/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @param resetFields false by default, but when true, unsaved field values are cleared * @param text optional text being parsed, to be included in any error message * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range * @since 1.3 */ public long computeMillis(boolean resetFields, String text) { return computeMillis(resetFields, (CharSequence) text); }
/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range */ public long computeMillis() { return computeMillis(false, (CharSequence) null); }
/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @param resetFields false by default, but when true, unsaved field values are cleared * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range */ public long computeMillis(boolean resetFields) { return computeMillis(resetFields, (CharSequence) null); }
/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @param resetFields false by default, but when true, unsaved field values are cleared * @param text optional text being parsed, to be included in any error message * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range * @since 1.3 */ public long computeMillis(boolean resetFields, String text) { return computeMillis(resetFields, (CharSequence) text); }
long doParseMillis(InternalParser parser, CharSequence text) { int newPos = parser.parseInto(this, text, 0); if (newPos >= 0) { if (newPos >= text.length()) { return computeMillis(true, text); } } else { newPos = ~newPos; } throw new IllegalArgumentException(FormatUtils.createErrorMessage(text.toString(), newPos)); }
long doParseMillis(InternalParser parser, CharSequence text) { int newPos = parser.parseInto(this, text, 0); if (newPos >= 0) { if (newPos >= text.length()) { return computeMillis(true, text); } } else { newPos = ~newPos; } throw new IllegalArgumentException(FormatUtils.createErrorMessage(text.toString(), newPos)); }
if (newPos >= 0) { if (newPos >= text.length()) { long millis = bucket.computeMillis(true, text); if (iOffsetParsed && bucket.getOffsetInteger() != null) { int parsedOffset = bucket.getOffsetInteger();
if (newPos >= 0) { if (newPos >= text.length()) { long millis = bucket.computeMillis(true, text); if (iOffsetParsed && bucket.getOffsetInteger() != null) { int parsedOffset = bucket.getOffsetInteger();
/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range */ public long computeMillis() { return computeMillis(false, null); }
if (newPos >= 0) { if (newPos >= text.length()) { long millis = bucket.computeMillis(true, text); if (bucket.getOffsetInteger() != null) { // treat withOffsetParsed() as being true int parsedOffset = bucket.getOffsetInteger();
if (newPos >= 0) { if (newPos >= text.length()) { long millis = bucket.computeMillis(true, text); if (bucket.getOffsetInteger() != null) { // treat withOffsetParsed() as being true int parsedOffset = bucket.getOffsetInteger();
/** * Computes the parsed datetime by setting the saved fields. * This method is idempotent, but it is not thread-safe. * * @param resetFields false by default, but when true, unsaved field values are cleared * @return milliseconds since 1970-01-01T00:00:00Z * @throws IllegalArgumentException if any field is out of range */ public long computeMillis(boolean resetFields) { return computeMillis(resetFields, null); }
if (newPos >= 0) { if (newPos >= text.length()) { long millis = bucket.computeMillis(true, text); if (iOffsetParsed && bucket.getOffsetInteger() != null) { int parsedOffset = bucket.getOffsetInteger();
if (newPos >= 0) { if (newPos >= text.length()) { long millis = bucket.computeMillis(true, text); if (iOffsetParsed && bucket.getOffsetInteger() != null) { int parsedOffset = bucket.getOffsetInteger();
instantLocal, chrono, iLocale, iPivotYear, defaultYear); int newPos = parser.parseInto(bucket, text, position); instant.setMillis(bucket.computeMillis(false, text)); if (iOffsetParsed && bucket.getOffsetInteger() != null) { int parsedOffset = bucket.getOffsetInteger();
instantLocal, chrono, iLocale, iPivotYear, defaultYear); int newPos = parser.parseInto(bucket, text, position); instant.setMillis(bucket.computeMillis(false, text)); if (iOffsetParsed && bucket.getOffsetInteger() != null) { int parsedOffset = bucket.getOffsetInteger();
if (compareReverse(first, months) >= 0 && compareReverse(first, days) <= 0) { saveField(DateTimeFieldType.year(), iDefaultYear); return computeMillis(resetFields, text);
if (compareReverse(first, months) >= 0 && compareReverse(first, days) <= 0) { saveField(DateTimeFieldType.year(), iDefaultYear); return computeMillis(resetFields, text);