org.jclouds.cloudstack.features
Interface NATApi


public interface NATApi

Provides synchronous access to cloudstack via their REST API.

See Also:

Method Summary
 AsyncCreateResponse createIPForwardingRule(String IPAddressId, String protocol, int startPort, CreateIPForwardingRuleOptions... options)
          Creates an ip forwarding rule
 String deleteIPForwardingRule(String id)
          Deletes an ip forwarding rule
 String disableStaticNATOnPublicIP(String IPAddressId)
          Disables static rule for given ip address
 void enableStaticNATForVirtualMachine(String virtualMachineId, String IPAddressId)
           
 IPForwardingRule getIPForwardingRule(String id)
          get a specific IPForwardingRule by id
 Set<IPForwardingRule> getIPForwardingRulesForIPAddress(String id)
          get a set of IPForwardingRules by ipaddress id
 Set<IPForwardingRule> getIPForwardingRulesForVirtualMachine(String id)
          get a set of IPForwardingRules by virtual machine id
 Set<IPForwardingRule> listIPForwardingRules(ListIPForwardingRulesOptions... options)
          List the ip forwarding rules
 

Method Detail

listIPForwardingRules

@Named(value="listIpForwardingRules")
Set<IPForwardingRule> listIPForwardingRules(ListIPForwardingRulesOptions... options)
List the ip forwarding rules

Parameters:
options - if present, how to constrain the list.
Returns:
IPForwardingRules matching query, or empty set, if no IPForwardingRules are found

getIPForwardingRule

@Named(value="listIpForwardingRules")
IPForwardingRule getIPForwardingRule(String id)
get a specific IPForwardingRule by id

Parameters:
id - IPForwardingRule to get
Returns:
IPForwardingRule or null if not found

getIPForwardingRulesForIPAddress

@Named(value="listIpForwardingRules")
Set<IPForwardingRule> getIPForwardingRulesForIPAddress(String id)
get a set of IPForwardingRules by ipaddress id

Parameters:
id - IPAddress of rule to get
Returns:
IPForwardingRule matching query or empty if not found

getIPForwardingRulesForVirtualMachine

@Named(value="listIpForwardingRules")
Set<IPForwardingRule> getIPForwardingRulesForVirtualMachine(String id)
get a set of IPForwardingRules by virtual machine id

Parameters:
id - virtual machine of rule to get
Returns:
IPForwardingRule matching query or empty set if not found

createIPForwardingRule

@Named(value="createIpForwardingRule")
AsyncCreateResponse createIPForwardingRule(String IPAddressId,
                                                 String protocol,
                                                 int startPort,
                                                 CreateIPForwardingRuleOptions... options)
Creates an ip forwarding rule

Parameters:
IPAddressId - the public IP address id of the forwarding rule, already associated via associateIp
protocol - the protocol for the rule. Valid values are TCP or UDP.
startPort - the start port for the rule
Returns:
response used to track creation

enableStaticNATForVirtualMachine

@Named(value="enableStaticNat")
void enableStaticNATForVirtualMachine(String virtualMachineId,
                                            String IPAddressId)

deleteIPForwardingRule

@Named(value="deleteIpForwardingRule")
String deleteIPForwardingRule(String id)
Deletes an ip forwarding rule

Parameters:
id - the id of the forwarding rule

disableStaticNATOnPublicIP

@Named(value="disableStaticNat")
String disableStaticNATOnPublicIP(String IPAddressId)
Disables static rule for given ip address

Parameters:
IPAddressId - the public IP address id for which static nat feature is being disabled


Copyright © 2009-2014 The Apache Software Foundation. All Rights Reserved.