@Test public void testToString() { long asn = 12345; assertThat(AsSet.of(asn).toString(), equalTo(String.valueOf(asn))); assertThat(AsSet.of(1, 2, 3).toString(), equalTo("{1,2,3}")); }
@Override public String toString() { if (_value.length == 1) { return Long.toString(_value[0]); } return "{" + StringUtils.join(_value, ',') + "}"; }
AsSet implements Serializable, Comparable<AsSet> { @Override public String toString() { if (_value.length == 1) { return Long.toString(_value[0]); } return "{" + StringUtils.join(_value, ',') + "}"; } }
AsSet implements Serializable, Comparable<AsSet> { @Override public String toString() { if (_value.length == 1) { return Long.toString(_value[0]); } return "{" + StringUtils.join(_value, ',') + "}"; } private  AsSet(long[] value, boolean confederation); }
AsSet implements Serializable, Comparable<AsSet> { @Override public String toString() { if (_value.length == 1) { return Long.toString(_value[0]); } return "{" + StringUtils.join(_value, ',') + "}"; } private  AsSet(long[] value, boolean confederation); static AsSet empty(); static AsSet of(long value); static AsSet of(long... value); static AsSet confedEmpty(); static AsSet confed(long... value); @Override int compareTo(AsSet o); boolean containsAs(long asn); @Override boolean equals(@Nullable Object o); @VisibleForTesting @JsonProperty(PROP_ASNS) SortedSet<Long> getAsns(); @Override int hashCode(); @JsonIgnore boolean isEmpty(); @JsonProperty(PROP_CONFEDERATION) boolean isConfederationAsSet(); AsSet removePrivateAs(); int size(); @Override String toString(); }
AsSet implements Serializable, Comparable<AsSet> { @Override public String toString() { if (_value.length == 1) { return Long.toString(_value[0]); } return "{" + StringUtils.join(_value, ',') + "}"; } private  AsSet(long[] value, boolean confederation); static AsSet empty(); static AsSet of(long value); static AsSet of(long... value); static AsSet confedEmpty(); static AsSet confed(long... value); @Override int compareTo(AsSet o); boolean containsAs(long asn); @Override boolean equals(@Nullable Object o); @VisibleForTesting @JsonProperty(PROP_ASNS) SortedSet<Long> getAsns(); @Override int hashCode(); @JsonIgnore boolean isEmpty(); @JsonProperty(PROP_CONFEDERATION) boolean isConfederationAsSet(); AsSet removePrivateAs(); int size(); @Override String toString();  }