Examples of OFError


Examples of org.openflow.protocol.OFError

    /** Return an OFError of the given type with the given xid */
    private OFMessage getErrorMessage(OFErrorType type,
                                      int i,
                                      int xid) {
        OFError e = (OFError) BasicFactory.getInstance()
                .getMessage(OFType.ERROR);
        e.setErrorType(type);
        e.setErrorCode((short)i);
        e.setXid(xid);
        return e;
    }
View Full Code Here

Examples of org.openflow.protocol.OFError

     */
    @Test
    public void testReassertMaster() throws Exception {
        testInitialMoveToMasterWithRole();

        OFError err = (OFError)
                BasicFactory.getInstance().getMessage(OFType.ERROR);
        err.setXid(42);
        err.setErrorType(OFErrorType.OFPET_BAD_REQUEST);
        err.setErrorCode(OFBadRequestCode.OFPBRC_EPERM);

        reset(controller);
        controller.reassertRole(handler, Role.MASTER);
        expectLastCall().once();
        controller.handleMessage(sw, err, null);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.