@Test public void testToString() { assertThat(ExtendedCommunity.parse("origin:65555:1").toString(), equalTo("515:65555L:1")); assertThat(ExtendedCommunity.parse("origin:1L:1").toString(), equalTo("515:1L:1")); assertThat(ExtendedCommunity.parse("origin:1:1").toString(), equalTo("3:1:1")); assertThat(ExtendedCommunity.parse("origin:0.0.0.0:1").toString(), equalTo("259:0L:1")); }
@Override @Nonnull @JsonValue public String toString() { if (_str == null) { String gaSuffix = _type == 0x00 || _type == 0x40 ? "" : "L"; _str = (((int) _type << 8) | _subType) + ":" + _globalAdministrator + gaSuffix + ":" + _localAdministrator; } return _str; }
ExtendedCommunity extends Community { @Override @Nonnull @JsonValue public String toString() { if (_str == null) { String gaSuffix = _type == 0x00 || _type == 0x40 ? "" : "L"; _str = (((int) _type << 8) | _subType) + ":" + _globalAdministrator + gaSuffix + ":" + _localAdministrator; } return _str; } }
ExtendedCommunity extends Community { @Override @Nonnull @JsonValue public String toString() { if (_str == null) { String gaSuffix = _type == 0x00 || _type == 0x40 ? "" : "L"; _str = (((int) _type << 8) | _subType) + ":" + _globalAdministrator + gaSuffix + ":" + _localAdministrator; } return _str; } private  ExtendedCommunity(
      byte type, byte subType, long globalAdministrator, long localAdministrator); }
ExtendedCommunity extends Community { @Override @Nonnull @JsonValue public String toString() { if (_str == null) { String gaSuffix = _type == 0x00 || _type == 0x40 ? "" : "L"; _str = (((int) _type << 8) | _subType) + ":" + _globalAdministrator + gaSuffix + ":" + _localAdministrator; } return _str; } private  ExtendedCommunity(
      byte type, byte subType, long globalAdministrator, long localAdministrator); @Nonnull static ExtendedCommunity parse(String communityStr); @Nonnull static Optional<ExtendedCommunity> tryParse(String text); static ExtendedCommunity of(int type, long globalAdministrator, long localAdministrator); static ExtendedCommunity of(int type, Ip globalAdministrator, long localAdministrator); static ExtendedCommunity target(long asn, long value); @Override T accept(CommunityVisitor<T> visitor); @Override boolean isTransitive(); boolean isRouteOrigin(); boolean isRouteTarget(); boolean isVpnDistinguisher(); long getGlobalAdministrator(); long getLocalAdministrator(); @Override boolean equals(@Nullable Object o); @Override int hashCode(); @Nonnull @Override String matchString(); @Override @Nonnull @JsonValue String toString(); }
ExtendedCommunity extends Community { @Override @Nonnull @JsonValue public String toString() { if (_str == null) { String gaSuffix = _type == 0x00 || _type == 0x40 ? "" : "L"; _str = (((int) _type << 8) | _subType) + ":" + _globalAdministrator + gaSuffix + ":" + _localAdministrator; } return _str; } private  ExtendedCommunity(
      byte type, byte subType, long globalAdministrator, long localAdministrator); @Nonnull static ExtendedCommunity parse(String communityStr); @Nonnull static Optional<ExtendedCommunity> tryParse(String text); static ExtendedCommunity of(int type, long globalAdministrator, long localAdministrator); static ExtendedCommunity of(int type, Ip globalAdministrator, long localAdministrator); static ExtendedCommunity target(long asn, long value); @Override T accept(CommunityVisitor<T> visitor); @Override boolean isTransitive(); boolean isRouteOrigin(); boolean isRouteTarget(); boolean isVpnDistinguisher(); long getGlobalAdministrator(); long getLocalAdministrator(); @Override boolean equals(@Nullable Object o); @Override int hashCode(); @Nonnull @Override String matchString(); @Override @Nonnull @JsonValue String toString();  }