org.jclouds.vcloud.domain.network.nat.rules
Class OneToOneVmRule

java.lang.Object
  extended by org.jclouds.vcloud.domain.network.nat.rules.OneToOneVmRule
All Implemented Interfaces:
NatRule

public class OneToOneVmRule
extends Object
implements NatRule

The OneToOneVmRule element describes a NAT rule that specifies network address translation details for a single virtual machine. The external IP address can be specified manually or assigned automatically at deployment time. The internal IP address is discovered by looking up the specified VmReference and NIC ID.

Since:
vcloud 0.9

Constructor Summary
OneToOneVmRule(MappingMode mappingMode, String externalIp, String vAppScopedVmId, int vmNicId)
           
 
Method Summary
 boolean equals(Object o)
           
 String getExternalIP()
          IP address to which this NAT rule maps the IP address specified in the InternalIp element.
 MappingMode getMappingMode()
           
 String getVAppScopedVmId()
           
 int getVmNicId()
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OneToOneVmRule

public OneToOneVmRule(MappingMode mappingMode,
                      @Nullable
                      String externalIp,
                      @Nullable
                      String vAppScopedVmId,
                      int vmNicId)
Method Detail

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

getMappingMode

public MappingMode getMappingMode()
Returns:
how IP address mapping is implemented by the NAT service
Since:
vcloud 0.9

getExternalIP

@Nullable
public String getExternalIP()
Description copied from interface: NatRule
IP address to which this NAT rule maps the IP address specified in the InternalIp element.

Specified by:
getExternalIP in interface NatRule
Returns:
if MappingMode is manual, specifies the external IP address of this Vm, otherwise null.
Since:
vcloud 0.9

getVAppScopedVmId

@Nullable
public String getVAppScopedVmId()
Returns:
read‐only identifier created on import
Since:
vcloud 0.9

getVmNicId

public int getVmNicId()
Returns:
device number of the NIC on the referenced virtual machine
Since:
vcloud 0.9


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