@Test public void testRfPrefixMoreSpecific() { Prefix6 acceptedPrefix1 = Prefix6.parse("2001:db8:1234:2345:5353:8373:8728:1239/66"); Prefix6 deniedPrefix1 = Prefix6.parse("2001:db8:4567:2345:5353:8373:8728:1239/66"); Prefix6 deniedPrefix2 = Prefix6.parse("2001:db8:1234:2345:5353:8373:8728:1239/62"); assertThat(_rfPrefixMoreSpecific, permits(acceptedPrefix1)); assertThat(_rfPrefixMoreSpecific, rejects(deniedPrefix1)); assertThat(_rfPrefixMoreSpecific, rejects(deniedPrefix2)); }
public boolean permits(Prefix6 prefix) { if (_deniedCache.get().contains(prefix)) { return false; } else if (_permittedCache.get().contains(prefix)) { return true; } return newPermits(prefix); }
Route6FilterList extends ComparableStructure<String> { public boolean permits(Prefix6 prefix) { if (_deniedCache.get().contains(prefix)) { return false; } else if (_permittedCache.get().contains(prefix)) { return true; } return newPermits(prefix); } }
Route6FilterList extends ComparableStructure<String> { public boolean permits(Prefix6 prefix) { if (_deniedCache.get().contains(prefix)) { return false; } else if (_permittedCache.get().contains(prefix)) { return true; } return newPermits(prefix); } Route6FilterList(String name); @JsonCreator  Route6FilterList(
      @JsonProperty(PROP_NAME) String name,
      @JsonProperty(PROP_LINES) List<Route6FilterLine> lines); }
Route6FilterList extends ComparableStructure<String> { public boolean permits(Prefix6 prefix) { if (_deniedCache.get().contains(prefix)) { return false; } else if (_permittedCache.get().contains(prefix)) { return true; } return newPermits(prefix); } Route6FilterList(String name); @JsonCreator  Route6FilterList(
      @JsonProperty(PROP_NAME) String name,
      @JsonProperty(PROP_LINES) List<Route6FilterLine> lines); void addLine(Route6FilterLine r); @Override boolean equals(Object o); @JsonProperty(PROP_LINES) List<Route6FilterLine> getLines(); boolean permits(Prefix6 prefix); @JsonProperty(PROP_LINES) void setLines(List<Route6FilterLine> lines); }
Route6FilterList extends ComparableStructure<String> { public boolean permits(Prefix6 prefix) { if (_deniedCache.get().contains(prefix)) { return false; } else if (_permittedCache.get().contains(prefix)) { return true; } return newPermits(prefix); } Route6FilterList(String name); @JsonCreator  Route6FilterList(
      @JsonProperty(PROP_NAME) String name,
      @JsonProperty(PROP_LINES) List<Route6FilterLine> lines); void addLine(Route6FilterLine r); @Override boolean equals(Object o); @JsonProperty(PROP_LINES) List<Route6FilterLine> getLines(); boolean permits(Prefix6 prefix); @JsonProperty(PROP_LINES) void setLines(List<Route6FilterLine> lines);  }