Package org.jclouds.cloudstack.features
Interface NetworkApi
public interface NetworkApi
Provides synchronous access to cloudstack via their REST API.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptioncreateNetworkInZone
(String zoneId, String networkOfferingId, String name, String displayText, CreateNetworkOptions... options) Creates a networkdeleteNetwork
(String id) Deletes a networkgetNetwork
(String id) get a specific network by idlistNetworks
(ListNetworksOptions... options) Lists networks
-
Method Details
-
listNetworks
@Named("listNetworks") @GET @Consumes("application/json") Set<Network> listNetworks(ListNetworksOptions... options) Lists networks- Parameters:
options
- if present, how to constrain the list.- Returns:
- networks matching query, or empty set, if no networks are found
-
getNetwork
@Named("listNetworks") @GET @Consumes("application/json") Network getNetwork(@QueryParam("id") String id) get a specific network by id- Parameters:
id
- network to get- Returns:
- network or null if not found
-
createNetworkInZone
@Named("createNetwork") @GET @Consumes("application/json") Network createNetworkInZone(@QueryParam("zoneid") String zoneId, @QueryParam("networkofferingid") String networkOfferingId, @QueryParam("name") String name, @QueryParam("displaytext") String displayText, CreateNetworkOptions... options) Creates a network- Parameters:
zoneId
- the Zone ID for the Vlan ip rangenetworkOfferingId
- the network offering idname
- the name of the networkdisplayText
- the display text of the networkoptions
- optional parameters- Returns:
- newly created network
-
deleteNetwork
@Named("deleteNetwork") @GET @Consumes("application/json") String deleteNetwork(@QueryParam("id") String id) Deletes a network- Parameters:
id
- the ID of the network- Returns:
- job id related to destroying the network, or null if resource was not found
-