public static OFMeterBandType readFrom(ChannelBuffer bb) throws OFParseError { try { return ofWireValue(bb.readShort()); } catch (IllegalArgumentException e) { throw new OFParseError(e); } }
public static OFMeterBandType ofWireValue(short val) { switch(val) { case DROP_VAL: return OFMeterBandType.DROP; case DSCP_REMARK_VAL: return OFMeterBandType.DSCP_REMARK; case EXPERIMENTER_VAL: return OFMeterBandType.EXPERIMENTER; default: throw new IllegalArgumentException("Illegal wire value for type OFMeterBandType in version 1.3: " + val); } }
public static short toWireValue(OFMeterBandType e) { switch(e) { case DROP: return DROP_VAL; case DSCP_REMARK: return DSCP_REMARK_VAL; case EXPERIMENTER: return EXPERIMENTER_VAL; default: throw new IllegalArgumentException("Illegal enum value for type OFMeterBandType in version 1.3: " + e); } }
public static OFMeterBandType ofWireValue(short val) { switch(val) { case DROP_VAL: return OFMeterBandType.DROP; case DSCP_REMARK_VAL: return OFMeterBandType.DSCP_REMARK; case EXPERIMENTER_VAL: return OFMeterBandType.EXPERIMENTER; default: throw new IllegalArgumentException("Illegal wire value for type OFMeterBandType in version 1.4: " + val); } }
public static short toWireValue(OFMeterBandType e) { switch(e) { case DROP: return DROP_VAL; case DSCP_REMARK: return DSCP_REMARK_VAL; case EXPERIMENTER: return EXPERIMENTER_VAL; default: throw new IllegalArgumentException("Illegal enum value for type OFMeterBandType in version 1.4: " + e); } }
public static OFMeterBandType readFrom(ByteBuf bb) throws OFParseError { try { return ofWireValue(bb.readShort()); } catch (IllegalArgumentException e) { throw new OFParseError(e); } }
public static OFMeterBandType ofWireValue(short val) { switch(val) { case DROP_VAL: return OFMeterBandType.DROP; case DSCP_REMARK_VAL: return OFMeterBandType.DSCP_REMARK; case EXPERIMENTER_VAL: return OFMeterBandType.EXPERIMENTER; default: throw new IllegalArgumentException("Illegal wire value for type OFMeterBandType in version 1.5: " + val); } }
public static short toWireValue(OFMeterBandType e) { switch(e) { case DROP: return DROP_VAL; case DSCP_REMARK: return DSCP_REMARK_VAL; case EXPERIMENTER: return EXPERIMENTER_VAL; default: throw new IllegalArgumentException("Illegal enum value for type OFMeterBandType in version 1.5: " + e); } }
public static void writeTo(ChannelBuffer bb, OFMeterBandType e) { bb.writeShort(toWireValue(e)); }
public static void putTo(OFMeterBandType e, PrimitiveSink sink) { sink.putShort(toWireValue(e)); }
public static void writeTo(ByteBuf bb, OFMeterBandType e) { bb.writeShort(toWireValue(e)); }