@Test public void validating_target_range_to_string() { TargetRange targetRange = TargetRange.from(RANGE_ZERO, RANGE_TEN); assertThat(targetRange).hasToString("TargetRange{" + "start=" + RANGE_ZERO + ", end=" + RANGE_TEN + '}'); }
public static TargetRange from(@IntRange(from = 0) int start, @IntRange(from = 0) int end) { if (end < start) { throw new IllegalArgumentException("The end of the range shouldn't be before the start"); } return new TargetRange(start, end); }
TargetRange { public static TargetRange from(@IntRange(from = 0) int start, @IntRange(from = 0) int end) { if (end < start) { throw new IllegalArgumentException("The end of the range shouldn't be before the start"); } return new TargetRange(start, end); } }
TargetRange { public static TargetRange from(@IntRange(from = 0) int start, @IntRange(from = 0) int end) { if (end < start) { throw new IllegalArgumentException("The end of the range shouldn't be before the start"); } return new TargetRange(start, end); } private  TargetRange(@IntRange(from = 0) int start, @IntRange(from = 0) int end); }
TargetRange { public static TargetRange from(@IntRange(from = 0) int start, @IntRange(from = 0) int end) { if (end < start) { throw new IllegalArgumentException("The end of the range shouldn't be before the start"); } return new TargetRange(start, end); } private  TargetRange(@IntRange(from = 0) int start, @IntRange(from = 0) int end); static TargetRange from(@IntRange(from = 0) int start, @IntRange(from = 0) int end); @IntRange(from = 0) int getStart(); @IntRange(from = 0) int getEnd(); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode(); }
TargetRange { public static TargetRange from(@IntRange(from = 0) int start, @IntRange(from = 0) int end) { if (end < start) { throw new IllegalArgumentException("The end of the range shouldn't be before the start"); } return new TargetRange(start, end); } private  TargetRange(@IntRange(from = 0) int start, @IntRange(from = 0) int end); static TargetRange from(@IntRange(from = 0) int start, @IntRange(from = 0) int end); @IntRange(from = 0) int getStart(); @IntRange(from = 0) int getEnd(); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode();  }