@Test public void testEcnsToAclLineMatchExpr() { assertEquals( PacketHeaderConstraintsToAclLineMatchExprUtils.ecnsToAclLineMatchExpr( IntegerSpace.of(new SubRange(10, 11))), match(HeaderSpace.builder().setEcns(ImmutableList.of(10, 11)).build())); }
@Nullable static AclLineMatchExpr ecnsToAclLineMatchExpr(@Nullable IntegerSpace ecns) { return Optional.ofNullable(ecns) .map(IntegerSpace::enumerate) .map(k -> match(HeaderSpace.builder().setEcns(k).build())) .orElse(null); }
PacketHeaderConstraintsToAclLineMatchExprUtils { @Nullable static AclLineMatchExpr ecnsToAclLineMatchExpr(@Nullable IntegerSpace ecns) { return Optional.ofNullable(ecns) .map(IntegerSpace::enumerate) .map(k -> match(HeaderSpace.builder().setEcns(k).build())) .orElse(null); } }
PacketHeaderConstraintsToAclLineMatchExprUtils { @Nullable static AclLineMatchExpr ecnsToAclLineMatchExpr(@Nullable IntegerSpace ecns) { return Optional.ofNullable(ecns) .map(IntegerSpace::enumerate) .map(k -> match(HeaderSpace.builder().setEcns(k).build())) .orElse(null); } private  PacketHeaderConstraintsToAclLineMatchExprUtils(); }
PacketHeaderConstraintsToAclLineMatchExprUtils { @Nullable static AclLineMatchExpr ecnsToAclLineMatchExpr(@Nullable IntegerSpace ecns) { return Optional.ofNullable(ecns) .map(IntegerSpace::enumerate) .map(k -> match(HeaderSpace.builder().setEcns(k).build())) .orElse(null); } private  PacketHeaderConstraintsToAclLineMatchExprUtils();  }
PacketHeaderConstraintsToAclLineMatchExprUtils { @Nullable static AclLineMatchExpr ecnsToAclLineMatchExpr(@Nullable IntegerSpace ecns) { return Optional.ofNullable(ecns) .map(IntegerSpace::enumerate) .map(k -> match(HeaderSpace.builder().setEcns(k).build())) .orElse(null); } private  PacketHeaderConstraintsToAclLineMatchExprUtils();   }