private static InstructionsBuilder createMeterInstructions() {
MeterBuilder aab = new MeterBuilder();
- aab.setMeterId(new MeterId(new Long(1)));
+ aab.setMeterId(new MeterId(1L));
InstructionBuilder ib = new InstructionBuilder();
ib.setInstruction(new MeterCaseBuilder().setMeter(aab.build()).build());
ActionBuilder ab = new ActionBuilder();
PushMplsActionBuilder push = new PushMplsActionBuilder();
- push.setEthernetType(new Integer(0x8847));
+ push.setEthernetType(0x8847);
ab.setAction(new PushMplsActionCaseBuilder().setPushMplsAction(push.build()).build());
actionList.add(ab.build());
// Create an Apply Action
ActionBuilder ab = new ActionBuilder();
PushPbbActionBuilder pbb = new PushPbbActionBuilder();
- pbb.setEthernetType(new Integer(0x88E7));
+ pbb.setEthernetType(0x88E7);
ab.setAction(new PushPbbActionCaseBuilder().setPushPbbAction(pbb.build()).build());
actionList.add(ab.build());
// Create an Apply Action
if (null == flow.isBarrier()) {
flow.setBarrier(Boolean.FALSE);
}
- // flow.setBufferId(new Long(12));
- BigInteger value = new BigInteger("10", 10);
- BigInteger outputPort = new BigInteger("4294967295", 10);
+ // flow.setBufferId(12L);
+ BigInteger value = BigInteger.valueOf(10);
+ BigInteger outputPort = BigInteger.valueOf(4294967295L);
flow.setCookie(new FlowCookie(value));
flow.setCookieMask(new FlowCookie(value));
flow.setHardTimeout(0);
flow.setFlags(new FlowModFlags(false, false, false, false, true));
flow.setId(new FlowId("12"));
flow.setTableId(getTableId(tableId));
- flow.setOutGroup(new Long("4294967295"));
+ flow.setOutGroup(4294967295L);
// set outport to OFPP_NONE (65535) to disable remove restriction for
// flow
flow.setOutPort(outputPort);
private List<Action> createPushVlanAction() {
PushVlanActionBuilder vlan = new PushVlanActionBuilder();
- vlan.setEthernetType(new Integer(0x8100));
+ vlan.setEthernetType(0x8100);
VlanId v = new VlanId(2);
vlan.setVlanId(v);
ActionBuilder action = new ActionBuilder();
private List<Action> createPushMplsAction() {
PushMplsActionBuilder push = new PushMplsActionBuilder();
- push.setEthernetType(new Integer(0x8847));
+ push.setEthernetType(0x8847);
ActionBuilder action = new ActionBuilder();
action.setAction(new PushMplsActionCaseBuilder().setPushMplsAction(push.build()).build());
List<Action> actions = new ArrayList<Action>();
private List<Action> createPushPbbAction() {
PushPbbActionBuilder pbb = new PushPbbActionBuilder();
- pbb.setEthernetType(new Integer(0x88E7));
+ pbb.setEthernetType(0x88E7);
ActionBuilder action = new ActionBuilder();
action.setAction(new PushPbbActionCaseBuilder().setPushPbbAction(pbb.build()).build());
List<Action> actions = new ArrayList<Action>();