@Test public void testToBuilder() { LocalRoute lr = new LocalRoute(ConcreteInterfaceAddress.parse("1.1.1.1/24"), "Ethernet0"); assertThat(lr, equalTo(lr.toBuilder().build())); }
@Override public AbstractRouteBuilder<Builder, LocalRoute> toBuilder() { return builder() .setNetwork(_network) .setAdmin(_admin) .setNonRouting(getNonRouting()) .setNonForwarding(getNonForwarding()) .setNextHopInterface(_nextHopInterface) .setSourcePrefixLength(_sourcePrefixLength) .setTag(_tag); }
LocalRoute extends AbstractRoute { @Override public AbstractRouteBuilder<Builder, LocalRoute> toBuilder() { return builder() .setNetwork(_network) .setAdmin(_admin) .setNonRouting(getNonRouting()) .setNonForwarding(getNonForwarding()) .setNextHopInterface(_nextHopInterface) .setSourcePrefixLength(_sourcePrefixLength) .setTag(_tag); } }
LocalRoute extends AbstractRoute { @Override public AbstractRouteBuilder<Builder, LocalRoute> toBuilder() { return builder() .setNetwork(_network) .setAdmin(_admin) .setNonRouting(getNonRouting()) .setNonForwarding(getNonForwarding()) .setNextHopInterface(_nextHopInterface) .setSourcePrefixLength(_sourcePrefixLength) .setTag(_tag); } LocalRoute(ConcreteInterfaceAddress interfaceAddress, String nextHopInterface); @VisibleForTesting  LocalRoute(Prefix network, String nextHopInterface, int sourcePrefixLength, int admin, long tag); }
LocalRoute extends AbstractRoute { @Override public AbstractRouteBuilder<Builder, LocalRoute> toBuilder() { return builder() .setNetwork(_network) .setAdmin(_admin) .setNonRouting(getNonRouting()) .setNonForwarding(getNonForwarding()) .setNextHopInterface(_nextHopInterface) .setSourcePrefixLength(_sourcePrefixLength) .setTag(_tag); } LocalRoute(ConcreteInterfaceAddress interfaceAddress, String nextHopInterface); @VisibleForTesting  LocalRoute(Prefix network, String nextHopInterface, int sourcePrefixLength, int admin, long tag); @Override Long getMetric(); @Nonnull @JsonIgnore(false) @JsonProperty(PROP_NEXT_HOP_INTERFACE) @Override String getNextHopInterface(); @Nonnull @Override Ip getNextHopIp(); @Override RoutingProtocol getProtocol(); @JsonProperty(PROP_SOURCE_PREFIX_LENGTH) int getSourcePrefixLength(); static Builder builder(); @Override AbstractRouteBuilder<Builder, LocalRoute> toBuilder(); @Override boolean equals(Object o); @Override int hashCode(); }
LocalRoute extends AbstractRoute { @Override public AbstractRouteBuilder<Builder, LocalRoute> toBuilder() { return builder() .setNetwork(_network) .setAdmin(_admin) .setNonRouting(getNonRouting()) .setNonForwarding(getNonForwarding()) .setNextHopInterface(_nextHopInterface) .setSourcePrefixLength(_sourcePrefixLength) .setTag(_tag); } LocalRoute(ConcreteInterfaceAddress interfaceAddress, String nextHopInterface); @VisibleForTesting  LocalRoute(Prefix network, String nextHopInterface, int sourcePrefixLength, int admin, long tag); @Override Long getMetric(); @Nonnull @JsonIgnore(false) @JsonProperty(PROP_NEXT_HOP_INTERFACE) @Override String getNextHopInterface(); @Nonnull @Override Ip getNextHopIp(); @Override RoutingProtocol getProtocol(); @JsonProperty(PROP_SOURCE_PREFIX_LENGTH) int getSourcePrefixLength(); static Builder builder(); @Override AbstractRouteBuilder<Builder, LocalRoute> toBuilder(); @Override boolean equals(Object o); @Override int hashCode();  }