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.elasticloadbalancing.model;
  

Information about a load balancer.

  
  public class LoadBalancerDescription implements SerializableCloneable {

    
The name of the load balancer.
  
      private String loadBalancerName;

    
The external DNS name of the load balancer.
  
      private String dNSName;

    
The Amazon Route 53 hosted zone associated with the load balancer.

For more information, see Using Domain Names With Elastic Load Balancing in the Elastic Load Balancing Developer Guide.

  
      private String canonicalHostedZoneName;

    
The ID of the Amazon Route 53 hosted zone name associated with the load balancer.
  
      private String canonicalHostedZoneNameID;

    
The listeners for the load balancer.
  
The policies defined for the load balancer.
  
      private Policies policies;

    
Information about the back-end servers.
  
The Availability Zones for the load balancer.
  
The IDs of the subnets for the load balancer.
  
The ID of the VPC for the load balancer.
  
      private String vPCId;

    
The IDs of the instances for the load balancer.
  
Information about the health checks conducted on the load balancer.
  
      private HealthCheck healthCheck;

    
The security group that you can use as part of your inbound rules for your load balancer's back-end application instances. To only allow traffic from load balancers, add a security group rule to your back end instance that specifies this source security group as the inbound source.
  
      private SourceSecurityGroup sourceSecurityGroup;

    
The security groups for the load balancer. Valid only for load balancers in a VPC.
 
The date and time the load balancer was created.
 
     private java.util.Date createdTime;

    
The type of load balancer. Valid only for load balancers in a VPC.

If Scheme is internet-facing, the load balancer has a public DNS name that resolves to a public IP address.

If Scheme is internal, the load balancer has a public DNS name that resolves to a private IP address.

 
     private String scheme;

    
Default constructor for a new LoadBalancerDescription object. Callers should use the setter or fluent setter (with...) methods to initialize this object after creating it.
 
     public LoadBalancerDescription() {}
    
    
The name of the load balancer.

Returns:
The name of the load balancer.
 
     public String getLoadBalancerName() {
         return ;
     }
    
    
The name of the load balancer.

Parameters:
loadBalancerName The name of the load balancer.
 
     public void setLoadBalancerName(String loadBalancerName) {
         this. = loadBalancerName;
     }
    
    
The name of the load balancer.

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

Parameters:
loadBalancerName The name of the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withLoadBalancerName(String loadBalancerName) {
         this. = loadBalancerName;
         return this;
     }

    
The external DNS name of the load balancer.

Returns:
The external DNS name of the load balancer.
 
     public String getDNSName() {
         return ;
     }
    
    
The external DNS name of the load balancer.

Parameters:
dNSName The external DNS name of the load balancer.
 
     public void setDNSName(String dNSName) {
         this. = dNSName;
     }
    
    
The external DNS name of the load balancer.

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

Parameters:
dNSName The external DNS name of the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withDNSName(String dNSName) {
         this. = dNSName;
         return this;
     }

    
The Amazon Route 53 hosted zone associated with the load balancer.

For more information, see Using Domain Names With Elastic Load Balancing in the Elastic Load Balancing Developer Guide.

Returns:
The Amazon Route 53 hosted zone associated with the load balancer.

For more information, see Using Domain Names With Elastic Load Balancing in the Elastic Load Balancing Developer Guide.

 
     public String getCanonicalHostedZoneName() {
         return ;
     }
    
    
The Amazon Route 53 hosted zone associated with the load balancer.

For more information, see Using Domain Names With Elastic Load Balancing in the Elastic Load Balancing Developer Guide.

Parameters:
canonicalHostedZoneName The Amazon Route 53 hosted zone associated with the load balancer.

For more information, see Using Domain Names With Elastic Load Balancing in the Elastic Load Balancing Developer Guide.

 
     public void setCanonicalHostedZoneName(String canonicalHostedZoneName) {
         this. = canonicalHostedZoneName;
     }
    
    
The Amazon Route 53 hosted zone associated with the load balancer.

For more information, see Using Domain Names With Elastic Load Balancing in the Elastic Load Balancing Developer Guide.

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

Parameters:
canonicalHostedZoneName The Amazon Route 53 hosted zone associated with the load balancer.

For more information, see Using Domain Names With Elastic Load Balancing in the Elastic Load Balancing Developer Guide.

Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withCanonicalHostedZoneName(String canonicalHostedZoneName) {
         this. = canonicalHostedZoneName;
         return this;
     }

    
The ID of the Amazon Route 53 hosted zone name associated with the load balancer.

Returns:
The ID of the Amazon Route 53 hosted zone name associated with the load balancer.
 
     public String getCanonicalHostedZoneNameID() {
         return ;
     }
    
    
The ID of the Amazon Route 53 hosted zone name associated with the load balancer.

Parameters:
canonicalHostedZoneNameID The ID of the Amazon Route 53 hosted zone name associated with the load balancer.
 
     public void setCanonicalHostedZoneNameID(String canonicalHostedZoneNameID) {
         this. = canonicalHostedZoneNameID;
     }
    
    
The ID of the Amazon Route 53 hosted zone name associated with the load balancer.

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

Parameters:
canonicalHostedZoneNameID The ID of the Amazon Route 53 hosted zone name associated with the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withCanonicalHostedZoneNameID(String canonicalHostedZoneNameID) {
         this. = canonicalHostedZoneNameID;
         return this;
     }

    
The listeners for the load balancer.

Returns:
The listeners for the load balancer.
 
         if ( == null) {
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
The listeners for the load balancer.

Parameters:
listenerDescriptions The listeners for the load balancer.
 
     public void setListenerDescriptions(java.util.Collection<ListenerDescriptionlistenerDescriptions) {
         if (listenerDescriptions == null) {
             this. = null;
             return;
         }
         com.amazonaws.internal.ListWithAutoConstructFlag<ListenerDescriptionlistenerDescriptionsCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<ListenerDescription>(listenerDescriptions.size());
         listenerDescriptionsCopy.addAll(listenerDescriptions);
         this. = listenerDescriptionsCopy;
     }
    
    
The listeners for the load balancer.

NOTE: This method appends the values to the existing list (if any). Use setListenerDescriptions(java.util.Collection) or withListenerDescriptions(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:
listenerDescriptions The listeners for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withListenerDescriptions(ListenerDescription... listenerDescriptions) {
         if (getListenerDescriptions() == nullsetListenerDescriptions(new java.util.ArrayList<ListenerDescription>(listenerDescriptions.length));
         for (ListenerDescription value : listenerDescriptions) {
             getListenerDescriptions().add(value);
         }
         return this;
     }
    
    
The listeners for the load balancer.

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

Parameters:
listenerDescriptions The listeners for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (listenerDescriptions == null) {
             this. = null;
         } else {
             com.amazonaws.internal.ListWithAutoConstructFlag<ListenerDescriptionlistenerDescriptionsCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<ListenerDescription>(listenerDescriptions.size());
             listenerDescriptionsCopy.addAll(listenerDescriptions);
             this. = listenerDescriptionsCopy;
         }
 
         return this;
     }

    
The policies defined for the load balancer.

Returns:
The policies defined for the load balancer.
 
     public Policies getPolicies() {
         return ;
     }
    
    
The policies defined for the load balancer.

Parameters:
policies The policies defined for the load balancer.
 
     public void setPolicies(Policies policies) {
         this. = policies;
     }
    
    
The policies defined for the load balancer.

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

Parameters:
policies The policies defined for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withPolicies(Policies policies) {
         this. = policies;
         return this;
     }

    
Information about the back-end servers.

Returns:
Information about the back-end servers.
 
         if ( == null) {
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
Information about the back-end servers.

Parameters:
backendServerDescriptions Information about the back-end servers.
 
     public void setBackendServerDescriptions(java.util.Collection<BackendServerDescriptionbackendServerDescriptions) {
         if (backendServerDescriptions == null) {
             this. = null;
             return;
         }
         com.amazonaws.internal.ListWithAutoConstructFlag<BackendServerDescriptionbackendServerDescriptionsCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<BackendServerDescription>(backendServerDescriptions.size());
         backendServerDescriptionsCopy.addAll(backendServerDescriptions);
         this. = backendServerDescriptionsCopy;
     }
    
    
Information about the back-end servers.

NOTE: This method appends the values to the existing list (if any). Use setBackendServerDescriptions(java.util.Collection) or withBackendServerDescriptions(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:
backendServerDescriptions Information about the back-end servers.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withBackendServerDescriptions(BackendServerDescription... backendServerDescriptions) {
         if (getBackendServerDescriptions() == nullsetBackendServerDescriptions(new java.util.ArrayList<BackendServerDescription>(backendServerDescriptions.length));
         for (BackendServerDescription value : backendServerDescriptions) {
             getBackendServerDescriptions().add(value);
         }
         return this;
     }
    
    
Information about the back-end servers.

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

Parameters:
backendServerDescriptions Information about the back-end servers.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (backendServerDescriptions == null) {
             this. = null;
         } else {
             com.amazonaws.internal.ListWithAutoConstructFlag<BackendServerDescriptionbackendServerDescriptionsCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<BackendServerDescription>(backendServerDescriptions.size());
             backendServerDescriptionsCopy.addAll(backendServerDescriptions);
             this. = backendServerDescriptionsCopy;
         }
 
         return this;
     }

    
The Availability Zones for the load balancer.

Returns:
The Availability Zones for the load balancer.
 
     public java.util.List<StringgetAvailabilityZones() {
         if ( == null) {
                = new com.amazonaws.internal.ListWithAutoConstructFlag<String>();
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
The Availability Zones for the load balancer.

Parameters:
availabilityZones The Availability Zones for the load balancer.
 
     public void setAvailabilityZones(java.util.Collection<StringavailabilityZones) {
         if (availabilityZones == null) {
             this. = null;
             return;
         }
         com.amazonaws.internal.ListWithAutoConstructFlag<StringavailabilityZonesCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<String>(availabilityZones.size());
         availabilityZonesCopy.addAll(availabilityZones);
         this. = availabilityZonesCopy;
     }
    
    
The Availability Zones for the load balancer.

NOTE: This method appends the values to the existing list (if any). Use setAvailabilityZones(java.util.Collection) or withAvailabilityZones(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:
availabilityZones The Availability Zones for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withAvailabilityZones(String... availabilityZones) {
         if (getAvailabilityZones() == nullsetAvailabilityZones(new java.util.ArrayList<String>(availabilityZones.length));
         for (String value : availabilityZones) {
             getAvailabilityZones().add(value);
         }
         return this;
     }
    
    
The Availability Zones for the load balancer.

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

Parameters:
availabilityZones The Availability Zones for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withAvailabilityZones(java.util.Collection<StringavailabilityZones) {
         if (availabilityZones == null) {
             this. = null;
         } else {
             com.amazonaws.internal.ListWithAutoConstructFlag<StringavailabilityZonesCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<String>(availabilityZones.size());
             availabilityZonesCopy.addAll(availabilityZones);
             this. = availabilityZonesCopy;
         }
 
         return this;
     }

    
The IDs of the subnets for the load balancer.

Returns:
The IDs of the subnets for the load balancer.
 
     public java.util.List<StringgetSubnets() {
         if ( == null) {
                = new com.amazonaws.internal.ListWithAutoConstructFlag<String>();
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
The IDs of the subnets for the load balancer.

Parameters:
subnets The IDs of the subnets for the load balancer.
 
     public void setSubnets(java.util.Collection<Stringsubnets) {
         if (subnets == null) {
             this. = null;
             return;
         }
         subnetsCopy.addAll(subnets);
         this. = subnetsCopy;
     }
    
    
The IDs of the subnets for the load balancer.

NOTE: This method appends the values to the existing list (if any). Use setSubnets(java.util.Collection) or withSubnets(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:
subnets The IDs of the subnets for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withSubnets(String... subnets) {
         if (getSubnets() == nullsetSubnets(new java.util.ArrayList<String>(subnets.length));
         for (String value : subnets) {
             getSubnets().add(value);
         }
         return this;
     }
    
    
The IDs of the subnets for the load balancer.

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

Parameters:
subnets The IDs of the subnets for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (subnets == null) {
             this. = null;
         } else {
             subnetsCopy.addAll(subnets);
             this. = subnetsCopy;
         }
 
         return this;
     }

    
The ID of the VPC for the load balancer.

Returns:
The ID of the VPC for the load balancer.
 
     public String getVPCId() {
         return ;
     }
    
    
The ID of the VPC for the load balancer.

Parameters:
vPCId The ID of the VPC for the load balancer.
 
     public void setVPCId(String vPCId) {
         this. = vPCId;
     }
    
    
The ID of the VPC for the load balancer.

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

Parameters:
vPCId The ID of the VPC for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withVPCId(String vPCId) {
         this. = vPCId;
         return this;
     }

    
The IDs of the instances for the load balancer.

Returns:
The IDs of the instances for the load balancer.
 
     public java.util.List<InstancegetInstances() {
         if ( == null) {
                = new com.amazonaws.internal.ListWithAutoConstructFlag<Instance>();
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
The IDs of the instances for the load balancer.

Parameters:
instances The IDs of the instances for the load balancer.
 
     public void setInstances(java.util.Collection<Instanceinstances) {
         if (instances == null) {
             this. = null;
             return;
         }
         instancesCopy.addAll(instances);
         this. = instancesCopy;
     }
    
    
The IDs of the instances for the load balancer.

NOTE: This method appends the values to the existing list (if any). Use setInstances(java.util.Collection) or withInstances(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:
instances The IDs of the instances for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withInstances(Instance... instances) {
         if (getInstances() == nullsetInstances(new java.util.ArrayList<Instance>(instances.length));
         for (Instance value : instances) {
             getInstances().add(value);
         }
         return this;
     }
    
    
The IDs of the instances for the load balancer.

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

Parameters:
instances The IDs of the instances for the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (instances == null) {
             this. = null;
         } else {
             com.amazonaws.internal.ListWithAutoConstructFlag<InstanceinstancesCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<Instance>(instances.size());
             instancesCopy.addAll(instances);
             this. = instancesCopy;
         }
 
         return this;
     }

    
Information about the health checks conducted on the load balancer.

Returns:
Information about the health checks conducted on the load balancer.
 
     public HealthCheck getHealthCheck() {
         return ;
     }
    
    
Information about the health checks conducted on the load balancer.

Parameters:
healthCheck Information about the health checks conducted on the load balancer.
 
     public void setHealthCheck(HealthCheck healthCheck) {
         this. = healthCheck;
     }
    
    
Information about the health checks conducted on the load balancer.

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

Parameters:
healthCheck Information about the health checks conducted on the load balancer.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withHealthCheck(HealthCheck healthCheck) {
         this. = healthCheck;
         return this;
     }

    
The security group that you can use as part of your inbound rules for your load balancer's back-end application instances. To only allow traffic from load balancers, add a security group rule to your back end instance that specifies this source security group as the inbound source.

Returns:
The security group that you can use as part of your inbound rules for your load balancer's back-end application instances. To only allow traffic from load balancers, add a security group rule to your back end instance that specifies this source security group as the inbound source.
 
         return ;
     }
    
    
The security group that you can use as part of your inbound rules for your load balancer's back-end application instances. To only allow traffic from load balancers, add a security group rule to your back end instance that specifies this source security group as the inbound source.

Parameters:
sourceSecurityGroup The security group that you can use as part of your inbound rules for your load balancer's back-end application instances. To only allow traffic from load balancers, add a security group rule to your back end instance that specifies this source security group as the inbound source.
 
     public void setSourceSecurityGroup(SourceSecurityGroup sourceSecurityGroup) {
         this. = sourceSecurityGroup;
     }
    
    
The security group that you can use as part of your inbound rules for your load balancer's back-end application instances. To only allow traffic from load balancers, add a security group rule to your back end instance that specifies this source security group as the inbound source.

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

Parameters:
sourceSecurityGroup The security group that you can use as part of your inbound rules for your load balancer's back-end application instances. To only allow traffic from load balancers, add a security group rule to your back end instance that specifies this source security group as the inbound source.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withSourceSecurityGroup(SourceSecurityGroup sourceSecurityGroup) {
         this. = sourceSecurityGroup;
         return this;
     }

    
The security groups for the load balancer. Valid only for load balancers in a VPC.

Returns:
The security groups for the load balancer. Valid only for load balancers in a VPC.
 
     public java.util.List<StringgetSecurityGroups() {
         if ( == null) {
                = new com.amazonaws.internal.ListWithAutoConstructFlag<String>();
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
The security groups for the load balancer. Valid only for load balancers in a VPC.

Parameters:
securityGroups The security groups for the load balancer. Valid only for load balancers in a VPC.
 
     public void setSecurityGroups(java.util.Collection<StringsecurityGroups) {
         if (securityGroups == null) {
             this. = null;
             return;
         }
         com.amazonaws.internal.ListWithAutoConstructFlag<StringsecurityGroupsCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<String>(securityGroups.size());
         securityGroupsCopy.addAll(securityGroups);
         this. = securityGroupsCopy;
     }
    
    
The security groups for the load balancer. Valid only for load balancers in a VPC.

NOTE: This method appends the values to the existing list (if any). Use setSecurityGroups(java.util.Collection) or withSecurityGroups(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:
securityGroups The security groups for the load balancer. Valid only for load balancers in a VPC.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withSecurityGroups(String... securityGroups) {
         if (getSecurityGroups() == nullsetSecurityGroups(new java.util.ArrayList<String>(securityGroups.length));
         for (String value : securityGroups) {
             getSecurityGroups().add(value);
         }
         return this;
     }
    
    
The security groups for the load balancer. Valid only for load balancers in a VPC.

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

Parameters:
securityGroups The security groups for the load balancer. Valid only for load balancers in a VPC.
Returns:
A reference to this updated object so that method calls can be chained together.
 
         if (securityGroups == null) {
             this. = null;
         } else {
             com.amazonaws.internal.ListWithAutoConstructFlag<StringsecurityGroupsCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<String>(securityGroups.size());
             securityGroupsCopy.addAll(securityGroups);
             this. = securityGroupsCopy;
         }
 
         return this;
     }

    
The date and time the load balancer was created.

Returns:
The date and time the load balancer was created.
 
     public java.util.Date getCreatedTime() {
         return ;
     }
    
    
The date and time the load balancer was created.

Parameters:
createdTime The date and time the load balancer was created.
 
     public void setCreatedTime(java.util.Date createdTime) {
         this. = createdTime;
     }
    
    
The date and time the load balancer was created.

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

Parameters:
createdTime The date and time the load balancer was created.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withCreatedTime(java.util.Date createdTime) {
         this. = createdTime;
         return this;
     }

    
The type of load balancer. Valid only for load balancers in a VPC.

If Scheme is internet-facing, the load balancer has a public DNS name that resolves to a public IP address.

If Scheme is internal, the load balancer has a public DNS name that resolves to a private IP address.

Returns:
The type of load balancer. Valid only for load balancers in a VPC.

If Scheme is internet-facing, the load balancer has a public DNS name that resolves to a public IP address.

If Scheme is internal, the load balancer has a public DNS name that resolves to a private IP address.

 
     public String getScheme() {
         return ;
     }
    
    
The type of load balancer. Valid only for load balancers in a VPC.

If Scheme is internet-facing, the load balancer has a public DNS name that resolves to a public IP address.

If Scheme is internal, the load balancer has a public DNS name that resolves to a private IP address.

Parameters:
scheme The type of load balancer. Valid only for load balancers in a VPC.

If Scheme is internet-facing, the load balancer has a public DNS name that resolves to a public IP address.

If Scheme is internal, the load balancer has a public DNS name that resolves to a private IP address.

 
     public void setScheme(String scheme) {
         this. = scheme;
     }
    
    
The type of load balancer. Valid only for load balancers in a VPC.

If Scheme is internet-facing, the load balancer has a public DNS name that resolves to a public IP address.

If Scheme is internal, the load balancer has a public DNS name that resolves to a private IP address.

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

Parameters:
scheme The type of load balancer. Valid only for load balancers in a VPC.

If Scheme is internet-facing, the load balancer has a public DNS name that resolves to a public IP address.

If Scheme is internal, the load balancer has a public DNS name that resolves to a private IP address.

Returns:
A reference to this updated object so that method calls can be chained together.
 
     public LoadBalancerDescription withScheme(String scheme) {
         this. = scheme;
         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 (getLoadBalancerName() != nullsb.append("LoadBalancerName: " + getLoadBalancerName() + ",");
         if (getDNSName() != nullsb.append("DNSName: " + getDNSName() + ",");
         if (getCanonicalHostedZoneName() != nullsb.append("CanonicalHostedZoneName: " + getCanonicalHostedZoneName() + ",");
         if (getCanonicalHostedZoneNameID() != nullsb.append("CanonicalHostedZoneNameID: " + getCanonicalHostedZoneNameID() + ",");
         if (getListenerDescriptions() != nullsb.append("ListenerDescriptions: " + getListenerDescriptions() + ",");
         if (getPolicies() != nullsb.append("Policies: " + getPolicies() + ",");
         if (getBackendServerDescriptions() != nullsb.append("BackendServerDescriptions: " + getBackendServerDescriptions() + ",");
         if (getAvailabilityZones() != nullsb.append("AvailabilityZones: " + getAvailabilityZones() + ",");
        if (getSubnets() != nullsb.append("Subnets: " + getSubnets() + ",");
        if (getVPCId() != nullsb.append("VPCId: " + getVPCId() + ",");
        if (getInstances() != nullsb.append("Instances: " + getInstances() + ",");
        if (getHealthCheck() != nullsb.append("HealthCheck: " + getHealthCheck() + ",");
        if (getSourceSecurityGroup() != nullsb.append("SourceSecurityGroup: " + getSourceSecurityGroup() + ",");
        if (getSecurityGroups() != nullsb.append("SecurityGroups: " + getSecurityGroups() + ",");
        if (getCreatedTime() != nullsb.append("CreatedTime: " + getCreatedTime() + ",");
        if (getScheme() != nullsb.append("Scheme: " + getScheme() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getLoadBalancerName() == null) ? 0 : getLoadBalancerName().hashCode()); 
        hashCode = prime * hashCode + ((getDNSName() == null) ? 0 : getDNSName().hashCode()); 
        hashCode = prime * hashCode + ((getCanonicalHostedZoneName() == null) ? 0 : getCanonicalHostedZoneName().hashCode()); 
        hashCode = prime * hashCode + ((getCanonicalHostedZoneNameID() == null) ? 0 : getCanonicalHostedZoneNameID().hashCode()); 
        hashCode = prime * hashCode + ((getListenerDescriptions() == null) ? 0 : getListenerDescriptions().hashCode()); 
        hashCode = prime * hashCode + ((getPolicies() == null) ? 0 : getPolicies().hashCode()); 
        hashCode = prime * hashCode + ((getBackendServerDescriptions() == null) ? 0 : getBackendServerDescriptions().hashCode()); 
        hashCode = prime * hashCode + ((getAvailabilityZones() == null) ? 0 : getAvailabilityZones().hashCode()); 
        hashCode = prime * hashCode + ((getSubnets() == null) ? 0 : getSubnets().hashCode()); 
        hashCode = prime * hashCode + ((getVPCId() == null) ? 0 : getVPCId().hashCode()); 
        hashCode = prime * hashCode + ((getInstances() == null) ? 0 : getInstances().hashCode()); 
        hashCode = prime * hashCode + ((getHealthCheck() == null) ? 0 : getHealthCheck().hashCode()); 
        hashCode = prime * hashCode + ((getSourceSecurityGroup() == null) ? 0 : getSourceSecurityGroup().hashCode()); 
        hashCode = prime * hashCode + ((getSecurityGroups() == null) ? 0 : getSecurityGroups().hashCode()); 
        hashCode = prime * hashCode + ((getCreatedTime() == null) ? 0 : getCreatedTime().hashCode()); 
        hashCode = prime * hashCode + ((getScheme() == null) ? 0 : getScheme().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof LoadBalancerDescription == falsereturn false;
        LoadBalancerDescription other = (LoadBalancerDescription)obj;
        
        if (other.getLoadBalancerName() == null ^ this.getLoadBalancerName() == nullreturn false;
        if (other.getLoadBalancerName() != null && other.getLoadBalancerName().equals(this.getLoadBalancerName()) == falsereturn false
        if (other.getDNSName() == null ^ this.getDNSName() == nullreturn false;
        if (other.getDNSName() != null && other.getDNSName().equals(this.getDNSName()) == falsereturn false
        if (other.getCanonicalHostedZoneName() == null ^ this.getCanonicalHostedZoneName() == nullreturn false;
        if (other.getCanonicalHostedZoneName() != null && other.getCanonicalHostedZoneName().equals(this.getCanonicalHostedZoneName()) == falsereturn false
        if (other.getCanonicalHostedZoneNameID() == null ^ this.getCanonicalHostedZoneNameID() == nullreturn false;
        if (other.getCanonicalHostedZoneNameID() != null && other.getCanonicalHostedZoneNameID().equals(this.getCanonicalHostedZoneNameID()) == falsereturn false
        if (other.getListenerDescriptions() == null ^ this.getListenerDescriptions() == nullreturn false;
        if (other.getListenerDescriptions() != null && other.getListenerDescriptions().equals(this.getListenerDescriptions()) == falsereturn false
        if (other.getPolicies() == null ^ this.getPolicies() == nullreturn false;
        if (other.getPolicies() != null && other.getPolicies().equals(this.getPolicies()) == falsereturn false
        if (other.getBackendServerDescriptions() == null ^ this.getBackendServerDescriptions() == nullreturn false;
        if (other.getBackendServerDescriptions() != null && other.getBackendServerDescriptions().equals(this.getBackendServerDescriptions()) == falsereturn false
        if (other.getAvailabilityZones() == null ^ this.getAvailabilityZones() == nullreturn false;
        if (other.getAvailabilityZones() != null && other.getAvailabilityZones().equals(this.getAvailabilityZones()) == falsereturn false
        if (other.getSubnets() == null ^ this.getSubnets() == nullreturn false;
        if (other.getSubnets() != null && other.getSubnets().equals(this.getSubnets()) == falsereturn false
        if (other.getVPCId() == null ^ this.getVPCId() == nullreturn false;
        if (other.getVPCId() != null && other.getVPCId().equals(this.getVPCId()) == falsereturn false
        if (other.getInstances() == null ^ this.getInstances() == nullreturn false;
        if (other.getInstances() != null && other.getInstances().equals(this.getInstances()) == falsereturn false
        if (other.getHealthCheck() == null ^ this.getHealthCheck() == nullreturn false;
        if (other.getHealthCheck() != null && other.getHealthCheck().equals(this.getHealthCheck()) == falsereturn false
        if (other.getSourceSecurityGroup() == null ^ this.getSourceSecurityGroup() == nullreturn false;
        if (other.getSourceSecurityGroup() != null && other.getSourceSecurityGroup().equals(this.getSourceSecurityGroup()) == falsereturn false
        if (other.getSecurityGroups() == null ^ this.getSecurityGroups() == nullreturn false;
        if (other.getSecurityGroups() != null && other.getSecurityGroups().equals(this.getSecurityGroups()) == falsereturn false
        if (other.getCreatedTime() == null ^ this.getCreatedTime() == nullreturn false;
        if (other.getCreatedTime() != null && other.getCreatedTime().equals(this.getCreatedTime()) == falsereturn false
        if (other.getScheme() == null ^ this.getScheme() == nullreturn false;
        if (other.getScheme() != null && other.getScheme().equals(this.getScheme()) == falsereturn false
        return true;
    }
    
    @Override
    public LoadBalancerDescription clone() {
        try {
            return (LoadBalancerDescriptionsuper.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