Java 类org.projectfloodlight.openflow.protocol.OFControllerRoleReason 实例源码

项目:openflowj-otn    文件:OFControllerRoleReasonSerializerVer14.java   
public static OFControllerRoleReason readFrom(ChannelBuffer bb) throws OFParseError {
    try {
        return ofWireValue(bb.readByte());
    } catch (IllegalArgumentException e) {
        throw new OFParseError(e);
    }
}
项目:openflowj-otn    文件:OFControllerRoleReasonSerializerVer14.java   
public static OFControllerRoleReason ofWireValue(byte val) {
    switch(val) {
        case MASTER_REQUEST_VAL:
            return OFControllerRoleReason.MASTER_REQUEST;
        case CONFIG_VAL:
            return OFControllerRoleReason.CONFIG;
        case EXPERIMENTER_VAL:
            return OFControllerRoleReason.EXPERIMENTER;
        default:
            throw new IllegalArgumentException("Illegal wire value for type OFControllerRoleReason in version 1.4: " + val);
    }
}
项目:openflowj-otn    文件:OFControllerRoleReasonSerializerVer14.java   
public static byte toWireValue(OFControllerRoleReason e) {
    switch(e) {
        case MASTER_REQUEST:
            return MASTER_REQUEST_VAL;
        case CONFIG:
            return CONFIG_VAL;
        case EXPERIMENTER:
            return EXPERIMENTER_VAL;
        default:
            throw new IllegalArgumentException("Illegal enum value for type OFControllerRoleReason in version 1.4: " + e);
    }
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer15.java   
public static OFControllerRoleReason readFrom(ByteBuf bb) throws OFParseError {
    try {
        return ofWireValue(bb.readByte());
    } catch (IllegalArgumentException e) {
        throw new OFParseError(e);
    }
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer15.java   
public static OFControllerRoleReason ofWireValue(byte val) {
    switch(val) {
        case MASTER_REQUEST_VAL:
            return OFControllerRoleReason.MASTER_REQUEST;
        case CONFIG_VAL:
            return OFControllerRoleReason.CONFIG;
        case EXPERIMENTER_VAL:
            return OFControllerRoleReason.EXPERIMENTER;
        default:
            throw new IllegalArgumentException("Illegal wire value for type OFControllerRoleReason in version 1.5: " + val);
    }
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer15.java   
public static byte toWireValue(OFControllerRoleReason e) {
    switch(e) {
        case MASTER_REQUEST:
            return MASTER_REQUEST_VAL;
        case CONFIG:
            return CONFIG_VAL;
        case EXPERIMENTER:
            return EXPERIMENTER_VAL;
        default:
            throw new IllegalArgumentException("Illegal enum value for type OFControllerRoleReason in version 1.5: " + e);
    }
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer14.java   
public static OFControllerRoleReason readFrom(ByteBuf bb) throws OFParseError {
    try {
        return ofWireValue(bb.readByte());
    } catch (IllegalArgumentException e) {
        throw new OFParseError(e);
    }
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer14.java   
public static OFControllerRoleReason ofWireValue(byte val) {
    switch(val) {
        case MASTER_REQUEST_VAL:
            return OFControllerRoleReason.MASTER_REQUEST;
        case CONFIG_VAL:
            return OFControllerRoleReason.CONFIG;
        case EXPERIMENTER_VAL:
            return OFControllerRoleReason.EXPERIMENTER;
        default:
            throw new IllegalArgumentException("Illegal wire value for type OFControllerRoleReason in version 1.4: " + val);
    }
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer14.java   
public static byte toWireValue(OFControllerRoleReason e) {
    switch(e) {
        case MASTER_REQUEST:
            return MASTER_REQUEST_VAL;
        case CONFIG:
            return CONFIG_VAL;
        case EXPERIMENTER:
            return EXPERIMENTER_VAL;
        default:
            throw new IllegalArgumentException("Illegal enum value for type OFControllerRoleReason in version 1.4: " + e);
    }
}
项目:openflowj-otn    文件:OFControllerRoleReasonSerializerVer14.java   
public static void writeTo(ChannelBuffer bb, OFControllerRoleReason e) {
    bb.writeByte(toWireValue(e));
}
项目:openflowj-otn    文件:OFControllerRoleReasonSerializerVer14.java   
public static void putTo(OFControllerRoleReason e, PrimitiveSink sink) {
    sink.putByte(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer15.java   
public static void writeTo(ByteBuf bb, OFControllerRoleReason e) {
    bb.writeByte(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer15.java   
public static void putTo(OFControllerRoleReason e, PrimitiveSink sink) {
    sink.putByte(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer14.java   
public static void writeTo(ByteBuf bb, OFControllerRoleReason e) {
    bb.writeByte(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFControllerRoleReasonSerializerVer14.java   
public static void putTo(OFControllerRoleReason e, PrimitiveSink sink) {
    sink.putByte(toWireValue(e));
}