|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.joda.time.DateTimeField
org.joda.time.field.DelegatedDateTimeField
org.joda.time.field.LenientDateTimeField
public class LenientDateTimeField
Converts a strict DateTimeField into a lenient one. By being lenient, the set method accepts out of bounds values, performing an addition instead.
LenientDateTimeField is thread-safe and immutable.
LenientChronology,
StrictDateTimeField,
Serialized Form| Constructor Summary | |
|---|---|
protected |
LenientDateTimeField(DateTimeField field,
Chronology base)
|
| Method Summary | |
|---|---|
static DateTimeField |
getInstance(DateTimeField field,
Chronology base)
Returns a lenient version of the given field. |
boolean |
isLenient()
Returns true if the set method is lenient. |
long |
set(long instant,
int value)
Set values which may be out of bounds by adding the difference between the new value and the current value. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected LenientDateTimeField(DateTimeField field,
Chronology base)
| Method Detail |
|---|
public static DateTimeField getInstance(DateTimeField field,
Chronology base)
public final boolean isLenient()
DateTimeField
isLenient in class DelegatedDateTimeField
public long set(long instant,
int value)
set in class DelegatedDateTimeFieldinstant - the milliseconds from 1970-01-01T00:00:00Z to set invalue - the value to set, in the units of the field
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||