@Test public void testIpWildcardSetIpSpace() { IpSpace ipSpace = IpWildcardSetIpSpace.builder() .including(IpWildcard.parse("1.2.3.0/24")) .excluding(EVEN_IPS) .build(); assertThat( _ipSpaceRepresentative.getRepresentative(ipSpace), equalTo(Optional.of(Ip.parse("1.2.3.1")))); }
public Optional<Ip> getRepresentative(IpSpace ipSpace) { return _ipSpaceToBDD .getBDDInteger() .getValueSatisfying(_ipSpaceToBDD.visit(ipSpace)) .map(Ip::create); }
IpSpaceRepresentative { public Optional<Ip> getRepresentative(IpSpace ipSpace) { return _ipSpaceToBDD .getBDDInteger() .getValueSatisfying(_ipSpaceToBDD.visit(ipSpace)) .map(Ip::create); } }
IpSpaceRepresentative { public Optional<Ip> getRepresentative(IpSpace ipSpace) { return _ipSpaceToBDD .getBDDInteger() .getValueSatisfying(_ipSpaceToBDD.visit(ipSpace)) .map(Ip::create); } IpSpaceRepresentative(); }
IpSpaceRepresentative { public Optional<Ip> getRepresentative(IpSpace ipSpace) { return _ipSpaceToBDD .getBDDInteger() .getValueSatisfying(_ipSpaceToBDD.visit(ipSpace)) .map(Ip::create); } IpSpaceRepresentative(); Optional<Ip> getRepresentative(IpSpace ipSpace); }
IpSpaceRepresentative { public Optional<Ip> getRepresentative(IpSpace ipSpace) { return _ipSpaceToBDD .getBDDInteger() .getValueSatisfying(_ipSpaceToBDD.visit(ipSpace)) .map(Ip::create); } IpSpaceRepresentative(); Optional<Ip> getRepresentative(IpSpace ipSpace);  }