The calculation will add a duration equivalent to the number of seconds expressed in milliseconds.
The following three lines are identical in effect:
DateTime added = dt.plusSeconds(6); DateTime added = dt.plus(Period.seconds(6)); DateTime added = dt.withFieldAdded(DurationFieldType.seconds(), 6);
This datetime instance is immutable and unaffected by this method call. @param seconds the amount of seconds to add, may be negative @return the new datetime plus the increased seconds @since 1.1
|
|
|
|