Skip to content

Commit

Permalink
Improve TemporalAmountParser roundOff method
Browse files Browse the repository at this point in the history
  • Loading branch information
vLuckyyy committed Feb 13, 2024
1 parent 1674799 commit 4cf57ed
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,9 @@ public abstract class TemporalAmountParser<T extends TemporalAmount> {

private Set<ChronoUnit> roundedUnits = new HashSet<>();

public void roundOff(ChronoUnit unit) {
roundedUnits.add(unit);
public TemporalAmountParser<T> roundOff(ChronoUnit unit) {
this.roundedUnits.add(unit);
return this;
}

static {
Expand Down

0 comments on commit 4cf57ed

Please sign in to comment.