Search in sources :

Example 1 with DisableStaticNatCmd

use of org.apache.cloudstack.api.command.user.nat.DisableStaticNatCmd in project cloudstack by apache.

the class NetworkProviderTest method deleteFloatingIp.

public void deleteFloatingIp(IPAddressVO ip) throws Exception {
    BaseCmd cmd = new DisableStaticNatCmd();
    BaseCmd proxy = ComponentContext.inject(cmd);
    ManagementServerMock.setParameter(proxy, "ipAddressId", BaseCmd.CommandType.LONG, ip.getId());
    try {
        proxy.execute();
    } catch (Exception e) {
        s_logger.debug("DisableStaticNatCmd exception: " + e);
        e.printStackTrace();
        throw e;
    }
}
Also used : DisableStaticNatCmd(org.apache.cloudstack.api.command.user.nat.DisableStaticNatCmd) BaseCmd(org.apache.cloudstack.api.BaseCmd) CloudException(com.cloud.exception.CloudException) IOException(java.io.IOException)

Aggregations

CloudException (com.cloud.exception.CloudException)1 IOException (java.io.IOException)1 BaseCmd (org.apache.cloudstack.api.BaseCmd)1 DisableStaticNatCmd (org.apache.cloudstack.api.command.user.nat.DisableStaticNatCmd)1