Package com.cloud.agent.api

Examples of com.cloud.agent.api.FindLogicalSwitchPortCommand


        @SuppressWarnings("unchecked")
        NiciraNvpList<LogicalSwitchPort> lspl = mock(NiciraNvpList.class);
        when(lspl.getResultCount()).thenReturn(0);
        when(_nvpApi.findLogicalSwitchPortsByUuid("aaaa", "bbbb")).thenReturn(lspl);

        FindLogicalSwitchPortAnswer flspa = (FindLogicalSwitchPortAnswer) _resource.executeRequest(new FindLogicalSwitchPortCommand("aaaa", "bbbb"));
        assertFalse(flspa.getResult());
    }
View Full Code Here


    public void testFindLogicalSwitchPortApiException() throws ConfigurationException, NiciraNvpApiException {
        _resource.configure("NiciraNvpResource", _parameters);

        when(_nvpApi.findLogicalSwitchPortsByUuid("aaaa", "bbbb")).thenThrow(new NiciraNvpApiException());

        FindLogicalSwitchPortAnswer flspa = (FindLogicalSwitchPortAnswer) _resource.executeRequest(new FindLogicalSwitchPortCommand("aaaa", "bbbb"));
        assertFalse(flspa.getResult());
    }
View Full Code Here

        HostVO niciraNvpHost = _hostDao.findById(niciraNvpDevice.getHostId());

        NiciraNvpNicMappingVO existingNicMap = _niciraNvpNicMappingDao
                .findByNicUuid(nicVO.getUuid());
        if (existingNicMap != null) {
            FindLogicalSwitchPortCommand findCmd = new FindLogicalSwitchPortCommand(
                    existingNicMap.getLogicalSwitchUuid(),
                    existingNicMap.getLogicalSwitchPortUuid());
            FindLogicalSwitchPortAnswer answer = (FindLogicalSwitchPortAnswer)_agentMgr
                    .easySend(niciraNvpHost.getId(), findCmd);
View Full Code Here

TOP

Related Classes of com.cloud.agent.api.FindLogicalSwitchPortCommand

Copyright © 2018 www.massapicom. 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.