Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
   /*
    * Copyright 2010-2015 Amazon.com, Inc. or its affiliates. All Rights Reserved.
    * 
    * Licensed under the Apache License, Version 2.0 (the "License").
    * You may not use this file except in compliance with the License.
    * A copy of the License is located at
    * 
    *  http://aws.amazon.com/apache2.0
    * 
   * or in the "license" file accompanying this file. This file is distributed
   * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
   * express or implied. See the License for the specific language governing
   * permissions and limitations under the License.
   */
  package com.amazonaws.services.ec2.model;
  

Describes a network interface.

  
  public class NetworkInterface implements SerializableCloneable {

    
The ID of the network interface.
  
      private String networkInterfaceId;

    
The ID of the subnet.
  
      private String subnetId;

    
The ID of the VPC.
  
      private String vpcId;

    
The Availability Zone.
  
      private String availabilityZone;

    
A description.
  
      private String description;

    
The AWS account ID of the owner of the network interface.
  
      private String ownerId;

    
The ID of the entity that launched the instance on your behalf (for example, AWS Management Console or Auto Scaling).
  
      private String requesterId;

    
Indicates whether the network interface is being managed by AWS.
  
      private Boolean requesterManaged;

    
The status of the network interface.

Constraints:
Allowed Values: available, attaching, in-use, detaching

  
      private String status;

    
The MAC address.
  
      private String macAddress;

    
The IP address of the network interface within the subnet.
  
      private String privateIpAddress;

    
The private DNS name.
  
      private String privateDnsName;

    
Indicates whether traffic to or from the instance is validated.
  
      private Boolean sourceDestCheck;

    
Any security groups for the network interface.
  
The network interface attachment.
 
     private NetworkInterfaceAttachment attachment;

    
The association information for an Elastic IP associated with the network interface.
 
     private NetworkInterfaceAssociation association;

    
Any tags assigned to the network interface.
 
The private IP addresses associated with the network interface.
 
The ID of the network interface.

Returns:
The ID of the network interface.
 
     public String getNetworkInterfaceId() {
         return ;
     }
    
    
The ID of the network interface.

Parameters:
networkInterfaceId The ID of the network interface.
 
     public void setNetworkInterfaceId(String networkInterfaceId) {
         this. = networkInterfaceId;
     }
    
    
The ID of the network interface.

Returns a reference to this object so that method calls can be chained together.

Parameters:
networkInterfaceId The ID of the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withNetworkInterfaceId(String networkInterfaceId) {
         this. = networkInterfaceId;
         return this;
     }

    
The ID of the subnet.

Returns:
The ID of the subnet.
 
     public String getSubnetId() {
         return ;
     }
    
    
The ID of the subnet.

Parameters:
subnetId The ID of the subnet.
 
     public void setSubnetId(String subnetId) {
         this. = subnetId;
     }
    
    
The ID of the subnet.

Returns a reference to this object so that method calls can be chained together.

Parameters:
subnetId The ID of the subnet.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withSubnetId(String subnetId) {
         this. = subnetId;
         return this;
     }

    
The ID of the VPC.

Returns:
The ID of the VPC.
 
     public String getVpcId() {
         return ;
     }
    
    
The ID of the VPC.

Parameters:
vpcId The ID of the VPC.
 
     public void setVpcId(String vpcId) {
         this. = vpcId;
     }
    
    
The ID of the VPC.

Returns a reference to this object so that method calls can be chained together.

Parameters:
vpcId The ID of the VPC.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withVpcId(String vpcId) {
         this. = vpcId;
         return this;
     }

    
The Availability Zone.

Returns:
The Availability Zone.
 
     public String getAvailabilityZone() {
         return ;
     }
    
    
The Availability Zone.

Parameters:
availabilityZone The Availability Zone.
 
     public void setAvailabilityZone(String availabilityZone) {
         this. = availabilityZone;
     }
    
    
The Availability Zone.

Returns a reference to this object so that method calls can be chained together.

Parameters:
availabilityZone The Availability Zone.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withAvailabilityZone(String availabilityZone) {
         this. = availabilityZone;
         return this;
     }

    
A description.

Returns:
A description.
 
     public String getDescription() {
         return ;
     }
    
    
A description.

Parameters:
description A description.
 
     public void setDescription(String description) {
         this. = description;
     }
    
    
A description.

Returns a reference to this object so that method calls can be chained together.

Parameters:
description A description.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withDescription(String description) {
         this. = description;
         return this;
     }

    
The AWS account ID of the owner of the network interface.

Returns:
The AWS account ID of the owner of the network interface.
 
     public String getOwnerId() {
         return ;
     }
    
    
The AWS account ID of the owner of the network interface.

Parameters:
ownerId The AWS account ID of the owner of the network interface.
 
     public void setOwnerId(String ownerId) {
         this. = ownerId;
     }
    
    
The AWS account ID of the owner of the network interface.

Returns a reference to this object so that method calls can be chained together.

Parameters:
ownerId The AWS account ID of the owner of the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withOwnerId(String ownerId) {
         this. = ownerId;
         return this;
     }

    
The ID of the entity that launched the instance on your behalf (for example, AWS Management Console or Auto Scaling).

Returns:
The ID of the entity that launched the instance on your behalf (for example, AWS Management Console or Auto Scaling).
 
     public String getRequesterId() {
         return ;
     }
    
    
The ID of the entity that launched the instance on your behalf (for example, AWS Management Console or Auto Scaling).

Parameters:
requesterId The ID of the entity that launched the instance on your behalf (for example, AWS Management Console or Auto Scaling).
 
     public void setRequesterId(String requesterId) {
         this. = requesterId;
     }
    
    
The ID of the entity that launched the instance on your behalf (for example, AWS Management Console or Auto Scaling).

Returns a reference to this object so that method calls can be chained together.

Parameters:
requesterId The ID of the entity that launched the instance on your behalf (for example, AWS Management Console or Auto Scaling).
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withRequesterId(String requesterId) {
         this. = requesterId;
         return this;
     }

    
Indicates whether the network interface is being managed by AWS.

Returns:
Indicates whether the network interface is being managed by AWS.
 
     public Boolean isRequesterManaged() {
         return ;
     }
    
    
Indicates whether the network interface is being managed by AWS.

Parameters:
requesterManaged Indicates whether the network interface is being managed by AWS.
 
     public void setRequesterManaged(Boolean requesterManaged) {
         this. = requesterManaged;
     }
    
    
Indicates whether the network interface is being managed by AWS.

Returns a reference to this object so that method calls can be chained together.

Parameters:
requesterManaged Indicates whether the network interface is being managed by AWS.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withRequesterManaged(Boolean requesterManaged) {
         this. = requesterManaged;
         return this;
     }

    
Indicates whether the network interface is being managed by AWS.

Returns:
Indicates whether the network interface is being managed by AWS.
 
     public Boolean getRequesterManaged() {
         return ;
     }

    
The status of the network interface.

Constraints:
Allowed Values: available, attaching, in-use, detaching

Returns:
The status of the network interface.
See also:
NetworkInterfaceStatus
 
     public String getStatus() {
         return ;
     }
    
    
The status of the network interface.

Constraints:
Allowed Values: available, attaching, in-use, detaching

Parameters:
status The status of the network interface.
See also:
NetworkInterfaceStatus
 
     public void setStatus(String status) {
         this. = status;
     }
    
    
The status of the network interface.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: available, attaching, in-use, detaching

Parameters:
status The status of the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
See also:
NetworkInterfaceStatus
 
     public NetworkInterface withStatus(String status) {
         this. = status;
         return this;
     }

    
The status of the network interface.

Constraints:
Allowed Values: available, attaching, in-use, detaching

Parameters:
status The status of the network interface.
See also:
NetworkInterfaceStatus
 
     public void setStatus(NetworkInterfaceStatus status) {
         this. = status.toString();
     }
    
    
The status of the network interface.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: available, attaching, in-use, detaching

Parameters:
status The status of the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
See also:
NetworkInterfaceStatus
 
         this. = status.toString();
         return this;
     }

    
The MAC address.

Returns:
The MAC address.
 
     public String getMacAddress() {
         return ;
     }
    
    
The MAC address.

Parameters:
macAddress The MAC address.
 
     public void setMacAddress(String macAddress) {
         this. = macAddress;
     }
    
    
The MAC address.

Returns a reference to this object so that method calls can be chained together.

Parameters:
macAddress The MAC address.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withMacAddress(String macAddress) {
         this. = macAddress;
         return this;
     }

    
The IP address of the network interface within the subnet.

Returns:
The IP address of the network interface within the subnet.
 
     public String getPrivateIpAddress() {
         return ;
     }
    
    
The IP address of the network interface within the subnet.

Parameters:
privateIpAddress The IP address of the network interface within the subnet.
 
     public void setPrivateIpAddress(String privateIpAddress) {
         this. = privateIpAddress;
     }
    
    
The IP address of the network interface within the subnet.

Returns a reference to this object so that method calls can be chained together.

Parameters:
privateIpAddress The IP address of the network interface within the subnet.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withPrivateIpAddress(String privateIpAddress) {
         this. = privateIpAddress;
         return this;
     }

    
The private DNS name.

Returns:
The private DNS name.
 
     public String getPrivateDnsName() {
         return ;
     }
    
    
The private DNS name.

Parameters:
privateDnsName The private DNS name.
 
     public void setPrivateDnsName(String privateDnsName) {
         this. = privateDnsName;
     }
    
    
The private DNS name.

Returns a reference to this object so that method calls can be chained together.

Parameters:
privateDnsName The private DNS name.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withPrivateDnsName(String privateDnsName) {
         this. = privateDnsName;
         return this;
     }

    
Indicates whether traffic to or from the instance is validated.

Returns:
Indicates whether traffic to or from the instance is validated.
 
     public Boolean isSourceDestCheck() {
         return ;
     }
    
    
Indicates whether traffic to or from the instance is validated.

Parameters:
sourceDestCheck Indicates whether traffic to or from the instance is validated.
 
     public void setSourceDestCheck(Boolean sourceDestCheck) {
         this. = sourceDestCheck;
     }
    
    
Indicates whether traffic to or from the instance is validated.

Returns a reference to this object so that method calls can be chained together.

Parameters:
sourceDestCheck Indicates whether traffic to or from the instance is validated.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withSourceDestCheck(Boolean sourceDestCheck) {
         this. = sourceDestCheck;
         return this;
     }

    
Indicates whether traffic to or from the instance is validated.

Returns:
Indicates whether traffic to or from the instance is validated.
 
     public Boolean getSourceDestCheck() {
         return ;
     }

    
Any security groups for the network interface.

Returns:
Any security groups for the network interface.
 
     public java.util.List<GroupIdentifiergetGroups() {
         if ( == null) {
                = new com.amazonaws.internal.ListWithAutoConstructFlag<GroupIdentifier>();
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
Any security groups for the network interface.

Parameters:
groups Any security groups for the network interface.
 
     public void setGroups(java.util.Collection<GroupIdentifiergroups) {
         if (groups == null) {
             this. = null;
             return;
         }
         groupsCopy.addAll(groups);
         this. = groupsCopy;
     }
    
    
Any security groups for the network interface.

NOTE: This method appends the values to the existing list (if any). Use setGroups(java.util.Collection) or withGroups(java.util.Collection) if you want to override the existing values.

Returns a reference to this object so that method calls can be chained together.

Parameters:
groups Any security groups for the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withGroups(GroupIdentifier... groups) {
         if (getGroups() == nullsetGroups(new java.util.ArrayList<GroupIdentifier>(groups.length));
         for (GroupIdentifier value : groups) {
             getGroups().add(value);
         }
         return this;
     }
    
    
Any security groups for the network interface.

Returns a reference to this object so that method calls can be chained together.

Parameters:
groups Any security groups for the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (groups == null) {
             this. = null;
         } else {
             groupsCopy.addAll(groups);
             this. = groupsCopy;
         }
 
         return this;
     }

    
The network interface attachment.

Returns:
The network interface attachment.
 
         return ;
     }
    
    
The network interface attachment.

Parameters:
attachment The network interface attachment.
 
     public void setAttachment(NetworkInterfaceAttachment attachment) {
         this. = attachment;
     }
    
    
The network interface attachment.

Returns a reference to this object so that method calls can be chained together.

Parameters:
attachment The network interface attachment.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         this. = attachment;
         return this;
     }

    
The association information for an Elastic IP associated with the network interface.

Returns:
The association information for an Elastic IP associated with the network interface.
 
         return ;
     }
    
    
The association information for an Elastic IP associated with the network interface.

Parameters:
association The association information for an Elastic IP associated with the network interface.
 
     public void setAssociation(NetworkInterfaceAssociation association) {
         this. = association;
     }
    
    
The association information for an Elastic IP associated with the network interface.

Returns a reference to this object so that method calls can be chained together.

Parameters:
association The association information for an Elastic IP associated with the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         this. = association;
         return this;
     }

    
Any tags assigned to the network interface.

Returns:
Any tags assigned to the network interface.
 
     public java.util.List<TaggetTagSet() {
         if ( == null) {
                = new com.amazonaws.internal.ListWithAutoConstructFlag<Tag>();
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
Any tags assigned to the network interface.

Parameters:
tagSet Any tags assigned to the network interface.
 
     public void setTagSet(java.util.Collection<TagtagSet) {
         if (tagSet == null) {
             this. = null;
             return;
         }
         tagSetCopy.addAll(tagSet);
         this. = tagSetCopy;
     }
    
    
Any tags assigned to the network interface.

NOTE: This method appends the values to the existing list (if any). Use setTagSet(java.util.Collection) or withTagSet(java.util.Collection) if you want to override the existing values.

Returns a reference to this object so that method calls can be chained together.

Parameters:
tagSet Any tags assigned to the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withTagSet(Tag... tagSet) {
         if (getTagSet() == nullsetTagSet(new java.util.ArrayList<Tag>(tagSet.length));
         for (Tag value : tagSet) {
             getTagSet().add(value);
         }
         return this;
     }
    
    
Any tags assigned to the network interface.

Returns a reference to this object so that method calls can be chained together.

Parameters:
tagSet Any tags assigned to the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public NetworkInterface withTagSet(java.util.Collection<TagtagSet) {
         if (tagSet == null) {
             this. = null;
         } else {
             com.amazonaws.internal.ListWithAutoConstructFlag<TagtagSetCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<Tag>(tagSet.size());
             tagSetCopy.addAll(tagSet);
             this. = tagSetCopy;
         }
 
         return this;
     }

    
The private IP addresses associated with the network interface.

Returns:
The private IP addresses associated with the network interface.
 
         if ( == null) {
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
The private IP addresses associated with the network interface.

Parameters:
privateIpAddresses The private IP addresses associated with the network interface.
 
     public void setPrivateIpAddresses(java.util.Collection<NetworkInterfacePrivateIpAddressprivateIpAddresses) {
         if (privateIpAddresses == null) {
             this. = null;
             return;
         }
         privateIpAddressesCopy.addAll(privateIpAddresses);
         this. = privateIpAddressesCopy;
     }
    
    
The private IP addresses associated with the network interface.

NOTE: This method appends the values to the existing list (if any). Use setPrivateIpAddresses(java.util.Collection) or withPrivateIpAddresses(java.util.Collection) if you want to override the existing values.

Returns a reference to this object so that method calls can be chained together.

Parameters:
privateIpAddresses The private IP addresses associated with the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (getPrivateIpAddresses() == nullsetPrivateIpAddresses(new java.util.ArrayList<NetworkInterfacePrivateIpAddress>(privateIpAddresses.length));
         for (NetworkInterfacePrivateIpAddress value : privateIpAddresses) {
             getPrivateIpAddresses().add(value);
         }
         return this;
     }
    
    
The private IP addresses associated with the network interface.

Returns a reference to this object so that method calls can be chained together.

Parameters:
privateIpAddresses The private IP addresses associated with the network interface.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (privateIpAddresses == null) {
             this. = null;
         } else {
             privateIpAddressesCopy.addAll(privateIpAddresses);
             this. = privateIpAddressesCopy;
         }
 
         return this;
     }

    
Returns a string representation of this object; useful for testing and debugging.

Returns:
A string representation of this object.
See also:
java.lang.Object.toString()
 
     @Override
     public String toString() {
         StringBuilder sb = new StringBuilder();
         sb.append("{");
         if (getNetworkInterfaceId() != nullsb.append("NetworkInterfaceId: " + getNetworkInterfaceId() + ",");
         if (getSubnetId() != nullsb.append("SubnetId: " + getSubnetId() + ",");
         if (getVpcId() != nullsb.append("VpcId: " + getVpcId() + ",");
         if (getAvailabilityZone() != nullsb.append("AvailabilityZone: " + getAvailabilityZone() + ",");
         if (getDescription() != nullsb.append("Description: " + getDescription() + ",");
         if (getOwnerId() != nullsb.append("OwnerId: " + getOwnerId() + ",");
         if (getRequesterId() != nullsb.append("RequesterId: " + getRequesterId() + ",");
         if (isRequesterManaged() != nullsb.append("RequesterManaged: " + isRequesterManaged() + ",");
         if (getStatus() != nullsb.append("Status: " + getStatus() + ",");
         if (getMacAddress() != nullsb.append("MacAddress: " + getMacAddress() + ",");
         if (getPrivateIpAddress() != nullsb.append("PrivateIpAddress: " + getPrivateIpAddress() + ",");
         if (getPrivateDnsName() != nullsb.append("PrivateDnsName: " + getPrivateDnsName() + ",");
         if (isSourceDestCheck() != nullsb.append("SourceDestCheck: " + isSourceDestCheck() + ",");
         if (getGroups() != nullsb.append("Groups: " + getGroups() + ",");
         if (getAttachment() != nullsb.append("Attachment: " + getAttachment() + ",");
         if (getAssociation() != nullsb.append("Association: " + getAssociation() + ",");
         if (getTagSet() != nullsb.append("TagSet: " + getTagSet() + ",");
         if (getPrivateIpAddresses() != nullsb.append("PrivateIpAddresses: " + getPrivateIpAddresses() );
         sb.append("}");
         return sb.toString();
     }
     
     @Override
     public int hashCode() {
         final int prime = 31;
         int hashCode = 1;
         
         hashCode = prime * hashCode + ((getNetworkInterfaceId() == null) ? 0 : getNetworkInterfaceId().hashCode()); 
         hashCode = prime * hashCode + ((getSubnetId() == null) ? 0 : getSubnetId().hashCode()); 
         hashCode = prime * hashCode + ((getVpcId() == null) ? 0 : getVpcId().hashCode()); 
         hashCode = prime * hashCode + ((getAvailabilityZone() == null) ? 0 : getAvailabilityZone().hashCode()); 
         hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); 
         hashCode = prime * hashCode + ((getOwnerId() == null) ? 0 : getOwnerId().hashCode()); 
         hashCode = prime * hashCode + ((getRequesterId() == null) ? 0 : getRequesterId().hashCode()); 
         hashCode = prime * hashCode + ((isRequesterManaged() == null) ? 0 : isRequesterManaged().hashCode()); 
         hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); 
         hashCode = prime * hashCode + ((getMacAddress() == null) ? 0 : getMacAddress().hashCode()); 
         hashCode = prime * hashCode + ((getPrivateIpAddress() == null) ? 0 : getPrivateIpAddress().hashCode()); 
         hashCode = prime * hashCode + ((getPrivateDnsName() == null) ? 0 : getPrivateDnsName().hashCode()); 
         hashCode = prime * hashCode + ((isSourceDestCheck() == null) ? 0 : isSourceDestCheck().hashCode()); 
         hashCode = prime * hashCode + ((getGroups() == null) ? 0 : getGroups().hashCode()); 
         hashCode = prime * hashCode + ((getAttachment() == null) ? 0 : getAttachment().hashCode()); 
         hashCode = prime * hashCode + ((getAssociation() == null) ? 0 : getAssociation().hashCode()); 
         hashCode = prime * hashCode + ((getTagSet() == null) ? 0 : getTagSet().hashCode()); 
         hashCode = prime * hashCode + ((getPrivateIpAddresses() == null) ? 0 : getPrivateIpAddresses().hashCode()); 
         return hashCode;
     }
     
     @Override
     public boolean equals(Object obj) {
         if (this == objreturn true;
         if (obj == nullreturn false;
 
         if (obj instanceof NetworkInterface == falsereturn false;
         NetworkInterface other = (NetworkInterface)obj;
         
         if (other.getNetworkInterfaceId() == null ^ this.getNetworkInterfaceId() == nullreturn false;
         if (other.getNetworkInterfaceId() != null && other.getNetworkInterfaceId().equals(this.getNetworkInterfaceId()) == falsereturn false
         if (other.getSubnetId() == null ^ this.getSubnetId() == nullreturn false;
         if (other.getSubnetId() != null && other.getSubnetId().equals(this.getSubnetId()) == falsereturn false
         if (other.getVpcId() == null ^ this.getVpcId() == nullreturn false;
         if (other.getVpcId() != null && other.getVpcId().equals(this.getVpcId()) == falsereturn false
         if (other.getAvailabilityZone() == null ^ this.getAvailabilityZone() == nullreturn false;
         if (other.getAvailabilityZone() != null && other.getAvailabilityZone().equals(this.getAvailabilityZone()) == falsereturn false
         if (other.getDescription() == null ^ this.getDescription() == nullreturn false;
         if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == falsereturn false
         if (other.getOwnerId() == null ^ this.getOwnerId() == nullreturn false;
         if (other.getOwnerId() != null && other.getOwnerId().equals(this.getOwnerId()) == falsereturn false
         if (other.getRequesterId() == null ^ this.getRequesterId() == nullreturn false;
         if (other.getRequesterId() != null && other.getRequesterId().equals(this.getRequesterId()) == falsereturn false
         if (other.isRequesterManaged() == null ^ this.isRequesterManaged() == nullreturn false;
         if (other.isRequesterManaged() != null && other.isRequesterManaged().equals(this.isRequesterManaged()) == falsereturn false
         if (other.getStatus() == null ^ this.getStatus() == nullreturn false;
         if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == falsereturn false
        if (other.getMacAddress() == null ^ this.getMacAddress() == nullreturn false;
        if (other.getMacAddress() != null && other.getMacAddress().equals(this.getMacAddress()) == falsereturn false
        if (other.getPrivateIpAddress() == null ^ this.getPrivateIpAddress() == nullreturn false;
        if (other.getPrivateIpAddress() != null && other.getPrivateIpAddress().equals(this.getPrivateIpAddress()) == falsereturn false
        if (other.getPrivateDnsName() == null ^ this.getPrivateDnsName() == nullreturn false;
        if (other.getPrivateDnsName() != null && other.getPrivateDnsName().equals(this.getPrivateDnsName()) == falsereturn false
        if (other.isSourceDestCheck() == null ^ this.isSourceDestCheck() == nullreturn false;
        if (other.isSourceDestCheck() != null && other.isSourceDestCheck().equals(this.isSourceDestCheck()) == falsereturn false
        if (other.getGroups() == null ^ this.getGroups() == nullreturn false;
        if (other.getGroups() != null && other.getGroups().equals(this.getGroups()) == falsereturn false
        if (other.getAttachment() == null ^ this.getAttachment() == nullreturn false;
        if (other.getAttachment() != null && other.getAttachment().equals(this.getAttachment()) == falsereturn false
        if (other.getAssociation() == null ^ this.getAssociation() == nullreturn false;
        if (other.getAssociation() != null && other.getAssociation().equals(this.getAssociation()) == falsereturn false
        if (other.getTagSet() == null ^ this.getTagSet() == nullreturn false;
        if (other.getTagSet() != null && other.getTagSet().equals(this.getTagSet()) == falsereturn false
        if (other.getPrivateIpAddresses() == null ^ this.getPrivateIpAddresses() == nullreturn false;
        if (other.getPrivateIpAddresses() != null && other.getPrivateIpAddresses().equals(this.getPrivateIpAddresses()) == falsereturn false
        return true;
    }
    
    @Override
    public NetworkInterface clone() {
        try {
            return (NetworkInterfacesuper.clone();
        
        } catch (CloneNotSupportedException e) {
            throw new IllegalStateException(
                    "Got a CloneNotSupportedException from Object.clone() "
                    + "even though we're Cloneable!",
                    e);
        }
        
    }
}
    
New to GrepCode? Check out our FAQ X