this.experimenterId = experimenterId;
}
- /**
- * Constructor.
- *
- * @param msgVersion protocol wire version
- * @param actionType type of action
- * @param experimenterId experimenter / vendor ID
- */
- @Deprecated(forRemoval = true)
- public ActionSerializerKey(final short msgVersion, final Class<T> actionType, final Long experimenterId) {
- this(msgVersion, actionType, experimenterId == null ? (Uint32) null : Uint32.valueOf(experimenterId));
- }
-
@Override
public int hashCode() {
final int prime = 31;
Assert.assertNotNull("Null key", key);
Assert.assertEquals("Wrong key", new ActionSerializerKey<>(EncodeConstants.OF13_VERSION_ID,
- OutputActionCase.class, (Uint32) null), key);
+ OutputActionCase.class, null), key);
}
/**
org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.action.rev150203.actions.grouping
.ActionBuilder builder = new ActionBuilder();
- builder.setExperimenterId(new ExperimenterId(42L));
+ builder.setExperimenterId(new ExperimenterId(Uint32.valueOf(42)));
builder.setActionChoice(new CopyTtlInCaseBuilder().build());
Action action = builder.build();
MessageTypeKey<?> key = keyMaker.make(action);
Assert.assertNotNull("Null key", key);
Assert.assertEquals("Wrong key", new ActionSerializerKey<>(EncodeConstants.OF13_VERSION_ID,
- CopyTtlInCase.class, 42L), key);
+ CopyTtlInCase.class, Uint32.valueOf(42)), key);
}
/**
Assert.assertNotNull("Null keyMaker", keyMaker);
InstructionBuilder builder = new InstructionBuilder();
- builder.setExperimenterId(new ExperimenterId(42L));
+ builder.setExperimenterId(new ExperimenterId(Uint32.valueOf(42)));
builder.setInstructionChoice(new ClearActionsCaseBuilder().build());
Instruction instruction = builder.build();
MessageTypeKey<?> key = keyMaker.make(instruction);
builder.setHasMask(true);
ExperimenterIdCaseBuilder caseBuilder = new ExperimenterIdCaseBuilder();
ExperimenterBuilder expBuilder = new ExperimenterBuilder();
- expBuilder.setExperimenter(new ExperimenterId(42L));
+ expBuilder.setExperimenter(new ExperimenterId(Uint32.valueOf(42)));
caseBuilder.setExperimenter(expBuilder.build());
builder.setMatchEntryValue(caseBuilder.build());
MatchEntry entry = builder.build();
import org.opendaylight.openflowplugin.openflow.md.core.session.OFSessionUtil;
import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.augments.rev150225.action.container.action.choice.ExperimenterIdCase;
import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.action.rev150203.actions.grouping.Action;
-import org.opendaylight.yangtools.yang.common.Uint32;
public final class ActionExtensionHelper {
convertor = extensionConvertorProvider.getActionConverter(key);
} else if (action.getActionChoice() != null) {
ActionSerializerKey<?> key = new ActionSerializerKey(EncodeConstants.OF13_VERSION_ID,
- action.getActionChoice().implementedInterface(), (Uint32) null);
+ action.getActionChoice().implementedInterface(), null);
convertor = extensionConvertorProvider.getActionConverter(key);
}