- Add the Codota plugin to your IDE and get smart completions
private void myMethod () {ArrayList a =
new ArrayList<String>()
new ArrayList()
new ArrayList<Object>()
- Smart code suggestions by Codota
}
protected void writeSections(Collection<ProtobufSystemInfo.Section> sections, JsonWriter json) { SystemInfoUtils .order(sections, ORDERED_SECTION_NAMES) .forEach(section -> writeSection(section, json)); }
@Test public void test_order() { Collection<Section> sections = asList( newSection("end2"), newSection("bar"), newSection("end1"), newSection("foo")); List<String> ordered = SystemInfoUtils.order(sections, "foo", "bar").stream() .map(Section::getName) .collect(Collectors.toList()); assertThat(ordered).isEqualTo(asList("foo", "bar", "end1", "end2")); }
protected void writeSections(Collection<ProtobufSystemInfo.Section> sections, JsonWriter json) { SystemInfoUtils .order(sections, ORDERED_SECTION_NAMES) .forEach(section -> writeSection(section, json)); }