Sho SHIMIZU
Committed by Gerrit Code Review

Simplify boolean expression

Change-Id: If0f8d497ac927bdd007292e45f0e394c207163d2
......@@ -430,7 +430,7 @@ public class BgpcepFlowRuleProvider extends AbstractProvider
Tunnel tunnel = tunnelService.queryTunnel(tunnelId);
PcepLabelObject labelObj = pc.factory().buildLabelObject()
.setOFlag(labelType == OUT_LABEL_TYPE ? true : false)
.setOFlag(labelType == OUT_LABEL_TYPE)
.setOptionalTlv(optionalTlv)
.setLabel((int) labelId.labelId())
.build();
......
......@@ -487,7 +487,7 @@ public class FlowEntryBuilder {
case MPLS_BOS:
@SuppressWarnings("unchecked")
OFOxm<U8> mplsBos = (OFOxm<U8>) oxm;
builder.setMplsBos(mplsBos.getValue() == U8.ZERO ? false : true);
builder.setMplsBos(mplsBos.getValue() != U8.ZERO);
break;
case TUNNEL_ID:
@SuppressWarnings("unchecked")
......