Interface SubnetApi
@Path("/subnets")
@Consumes("application/json")
@Produces("application/json")
public interface SubnetApi
Provides access to Subnet operations for the OpenStack Networking (Neutron) v2 API.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptioncreate
(Subnet.CreateSubnet subnet) Create a subnet within a specified networkcom.google.common.collect.FluentIterable
<Subnet> createBulk
(List<Subnet.CreateSubnet> subnets) Create multiple subnetsboolean
Delete a subnetReturns the specific Subnet.list()
Returns the list of all subnets currently defined in Neutron for the current tenant.list
(PaginationOptions options) update
(String id, Subnet.UpdateSubnet subnet) Update a subnet
-
Method Details
-
list
Returns the list of all subnets currently defined in Neutron for the current tenant. The list provides the unique identifier of each subnet configured for the tenant.- Returns:
- the list of all subnet references configured for the tenant
-
list
- See Also:
-
get
Returns the specific Subnet.- Parameters:
id
- the id of the subnet to return- Returns:
- Subnet or null if not found
-
create
Create a subnet within a specified network- Parameters:
subnet
- the subnet to be created- Returns:
- a reference of the newly-created subnet
-
createBulk
@Named("subnet:createBulk") @POST com.google.common.collect.FluentIterable<Subnet> createBulk(List<Subnet.CreateSubnet> subnets) Create multiple subnets- Parameters:
subnets
- the bulk of subnets to create- Returns:
- list of references of the newly-created subnets
-
update
@Named("subnet:update") @PUT @Path("/{id}") Subnet update(@PathParam("id") String id, Subnet.UpdateSubnet subnet) Update a subnet- Parameters:
id
- the id of the subnet to update- Returns:
- true if update was successful, false if not
-
delete
Delete a subnet- Parameters:
id
- the id of the subnet to delete- Returns:
- true if delete successful, false if not
-