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

项目:openflowj-otn    文件:OFBundleCtrlTypeSerializerVer14.java   
public static OFBundleCtrlType ofWireValue(short val) {
    switch(val) {
        case OPEN_REQUEST_VAL:
            return OFBundleCtrlType.OPEN_REQUEST;
        case OPEN_REPLY_VAL:
            return OFBundleCtrlType.OPEN_REPLY;
        case CLOSE_REQUEST_VAL:
            return OFBundleCtrlType.CLOSE_REQUEST;
        case CLOSE_REPLY_VAL:
            return OFBundleCtrlType.CLOSE_REPLY;
        case COMMIT_REQUEST_VAL:
            return OFBundleCtrlType.COMMIT_REQUEST;
        case COMMIT_REPLY_VAL:
            return OFBundleCtrlType.COMMIT_REPLY;
        case DISCARD_REQUEST_VAL:
            return OFBundleCtrlType.DISCARD_REQUEST;
        case DISCARD_REPLY_VAL:
            return OFBundleCtrlType.DISCARD_REPLY;
        default:
            throw new IllegalArgumentException("Illegal wire value for type OFBundleCtrlType in version 1.4: " + val);
    }
}
项目:openflowj-otn    文件:OFBundleCtrlTypeSerializerVer14.java   
public static short toWireValue(OFBundleCtrlType e) {
    switch(e) {
        case OPEN_REQUEST:
            return OPEN_REQUEST_VAL;
        case OPEN_REPLY:
            return OPEN_REPLY_VAL;
        case CLOSE_REQUEST:
            return CLOSE_REQUEST_VAL;
        case CLOSE_REPLY:
            return CLOSE_REPLY_VAL;
        case COMMIT_REQUEST:
            return COMMIT_REQUEST_VAL;
        case COMMIT_REPLY:
            return COMMIT_REPLY_VAL;
        case DISCARD_REQUEST:
            return DISCARD_REQUEST_VAL;
        case DISCARD_REPLY:
            return DISCARD_REPLY_VAL;
        default:
            throw new IllegalArgumentException("Illegal enum value for type OFBundleCtrlType in version 1.4: " + e);
    }
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer15.java   
public static OFBundleCtrlType ofWireValue(short val) {
    switch(val) {
        case OPEN_REQUEST_VAL:
            return OFBundleCtrlType.OPEN_REQUEST;
        case OPEN_REPLY_VAL:
            return OFBundleCtrlType.OPEN_REPLY;
        case CLOSE_REQUEST_VAL:
            return OFBundleCtrlType.CLOSE_REQUEST;
        case CLOSE_REPLY_VAL:
            return OFBundleCtrlType.CLOSE_REPLY;
        case COMMIT_REQUEST_VAL:
            return OFBundleCtrlType.COMMIT_REQUEST;
        case COMMIT_REPLY_VAL:
            return OFBundleCtrlType.COMMIT_REPLY;
        case DISCARD_REQUEST_VAL:
            return OFBundleCtrlType.DISCARD_REQUEST;
        case DISCARD_REPLY_VAL:
            return OFBundleCtrlType.DISCARD_REPLY;
        default:
            throw new IllegalArgumentException("Illegal wire value for type OFBundleCtrlType in version 1.5: " + val);
    }
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer15.java   
public static short toWireValue(OFBundleCtrlType e) {
    switch(e) {
        case OPEN_REQUEST:
            return OPEN_REQUEST_VAL;
        case OPEN_REPLY:
            return OPEN_REPLY_VAL;
        case CLOSE_REQUEST:
            return CLOSE_REQUEST_VAL;
        case CLOSE_REPLY:
            return CLOSE_REPLY_VAL;
        case COMMIT_REQUEST:
            return COMMIT_REQUEST_VAL;
        case COMMIT_REPLY:
            return COMMIT_REPLY_VAL;
        case DISCARD_REQUEST:
            return DISCARD_REQUEST_VAL;
        case DISCARD_REPLY:
            return DISCARD_REPLY_VAL;
        default:
            throw new IllegalArgumentException("Illegal enum value for type OFBundleCtrlType in version 1.5: " + e);
    }
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer14.java   
public static OFBundleCtrlType ofWireValue(short val) {
    switch(val) {
        case OPEN_REQUEST_VAL:
            return OFBundleCtrlType.OPEN_REQUEST;
        case OPEN_REPLY_VAL:
            return OFBundleCtrlType.OPEN_REPLY;
        case CLOSE_REQUEST_VAL:
            return OFBundleCtrlType.CLOSE_REQUEST;
        case CLOSE_REPLY_VAL:
            return OFBundleCtrlType.CLOSE_REPLY;
        case COMMIT_REQUEST_VAL:
            return OFBundleCtrlType.COMMIT_REQUEST;
        case COMMIT_REPLY_VAL:
            return OFBundleCtrlType.COMMIT_REPLY;
        case DISCARD_REQUEST_VAL:
            return OFBundleCtrlType.DISCARD_REQUEST;
        case DISCARD_REPLY_VAL:
            return OFBundleCtrlType.DISCARD_REPLY;
        default:
            throw new IllegalArgumentException("Illegal wire value for type OFBundleCtrlType in version 1.4: " + val);
    }
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer14.java   
public static short toWireValue(OFBundleCtrlType e) {
    switch(e) {
        case OPEN_REQUEST:
            return OPEN_REQUEST_VAL;
        case OPEN_REPLY:
            return OPEN_REPLY_VAL;
        case CLOSE_REQUEST:
            return CLOSE_REQUEST_VAL;
        case CLOSE_REPLY:
            return CLOSE_REPLY_VAL;
        case COMMIT_REQUEST:
            return COMMIT_REQUEST_VAL;
        case COMMIT_REPLY:
            return COMMIT_REPLY_VAL;
        case DISCARD_REQUEST:
            return DISCARD_REQUEST_VAL;
        case DISCARD_REPLY:
            return DISCARD_REPLY_VAL;
        default:
            throw new IllegalArgumentException("Illegal enum value for type OFBundleCtrlType in version 1.4: " + e);
    }
}
项目:openflowj-otn    文件:OFBundleCtrlTypeSerializerVer14.java   
public static OFBundleCtrlType readFrom(ChannelBuffer bb) throws OFParseError {
    try {
        return ofWireValue(bb.readShort());
    } catch (IllegalArgumentException e) {
        throw new OFParseError(e);
    }
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer15.java   
public static OFBundleCtrlType readFrom(ByteBuf bb) throws OFParseError {
    try {
        return ofWireValue(bb.readShort());
    } catch (IllegalArgumentException e) {
        throw new OFParseError(e);
    }
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer14.java   
public static OFBundleCtrlType readFrom(ByteBuf bb) throws OFParseError {
    try {
        return ofWireValue(bb.readShort());
    } catch (IllegalArgumentException e) {
        throw new OFParseError(e);
    }
}
项目:openflowj-otn    文件:OFBundleCtrlTypeSerializerVer14.java   
public static void writeTo(ChannelBuffer bb, OFBundleCtrlType e) {
    bb.writeShort(toWireValue(e));
}
项目:openflowj-otn    文件:OFBundleCtrlTypeSerializerVer14.java   
public static void putTo(OFBundleCtrlType e, PrimitiveSink sink) {
    sink.putShort(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer15.java   
public static void writeTo(ByteBuf bb, OFBundleCtrlType e) {
    bb.writeShort(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer15.java   
public static void putTo(OFBundleCtrlType e, PrimitiveSink sink) {
    sink.putShort(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer14.java   
public static void writeTo(ByteBuf bb, OFBundleCtrlType e) {
    bb.writeShort(toWireValue(e));
}
项目:loxigen-artifacts    文件:OFBundleCtrlTypeSerializerVer14.java   
public static void putTo(OFBundleCtrlType e, PrimitiveSink sink) {
    sink.putShort(toWireValue(e));
}