@Test public void labelsMustNotIncludeEmptySegments() { Throwable thrown = Assertions.assertThrows(InvalidPatternException.class, () -> { String target = " SmithyPattern.builder() .segments(parser(target)) .pattern(target) .build(); }); assertThat(thrown.getMessage(), containsString("Segments must not be empty")); }
public static Builder builder() { return new Builder(); }
SmithyPattern { public static Builder builder() { return new Builder(); } }
SmithyPattern { public static Builder builder() { return new Builder(); } protected  SmithyPattern(Builder builder); }
SmithyPattern { public static Builder builder() { return new Builder(); } protected  SmithyPattern(Builder builder); final List<Segment> getSegments(); final List<Segment> getLabels(); final Optional<Segment> getLabel(String name); final Optional<Segment> getGreedyLabel(); @Override String toString(); @Override boolean equals(Object other); @Override int hashCode(); static Builder builder(); }
SmithyPattern { public static Builder builder() { return new Builder(); } protected  SmithyPattern(Builder builder); final List<Segment> getSegments(); final List<Segment> getLabels(); final Optional<Segment> getLabel(String name); final Optional<Segment> getGreedyLabel(); @Override String toString(); @Override boolean equals(Object other); @Override int hashCode(); static Builder builder();  }