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

A JSON object containing the following fields:

 
 public class DescribeGatewayInformationResult implements SerializableCloneable {

    
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.

Constraints:
Length: 50 - 500

 
     private String gatewayARN;

    
The gateway ID.

Constraints:
Length: 12 - 30

 
     private String gatewayId;

    
One of the values that indicates the time zone configured for the gateway.

Constraints:
Length: 3 - 10

 
     private String gatewayTimezone;

    
One of the values that indicates the operating state of the gateway.

Constraints:
Length: 2 - 25

 
     private String gatewayState;

    
A NetworkInterface array that contains descriptions of the gateway network interfaces.
 
TBD

Constraints:
Length: 2 - 20

 
     private String gatewayType;

    
The date at which an update to the gateway is available. This date is in the time zone of the gateway. If the gateway is not available for an update this field is not returned in the response.

Constraints:
Length: 1 - 25

 
     private String nextUpdateAvailabilityDate;

    
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.

Constraints:
Length: 50 - 500

Returns:
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.
 
     public String getGatewayARN() {
         return ;
     }
    
    
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.

Constraints:
Length: 50 - 500

Parameters:
gatewayARN The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.
    public void setGatewayARN(String gatewayARN) {
        this. = gatewayARN;
    }
    
    
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.

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

Constraints:
Length: 50 - 500

Parameters:
gatewayARN The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = gatewayARN;
        return this;
    }

    
The gateway ID.

Constraints:
Length: 12 - 30

Returns:
The gateway ID.
    public String getGatewayId() {
        return ;
    }
    
    
The gateway ID.

Constraints:
Length: 12 - 30

Parameters:
gatewayId The gateway ID.
    public void setGatewayId(String gatewayId) {
        this. = gatewayId;
    }
    
    
The gateway ID.

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

Constraints:
Length: 12 - 30

Parameters:
gatewayId The gateway ID.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = gatewayId;
        return this;
    }

    
One of the values that indicates the time zone configured for the gateway.

Constraints:
Length: 3 - 10

Returns:
One of the values that indicates the time zone configured for the gateway.
    public String getGatewayTimezone() {
        return ;
    }
    
    
One of the values that indicates the time zone configured for the gateway.

Constraints:
Length: 3 - 10

Parameters:
gatewayTimezone One of the values that indicates the time zone configured for the gateway.
    public void setGatewayTimezone(String gatewayTimezone) {
        this. = gatewayTimezone;
    }
    
    
One of the values that indicates the time zone configured for the gateway.

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

Constraints:
Length: 3 - 10

Parameters:
gatewayTimezone One of the values that indicates the time zone configured for the gateway.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeGatewayInformationResult withGatewayTimezone(String gatewayTimezone) {
        this. = gatewayTimezone;
        return this;
    }

    
One of the values that indicates the operating state of the gateway.

Constraints:
Length: 2 - 25

Returns:
One of the values that indicates the operating state of the gateway.
    public String getGatewayState() {
        return ;
    }
    
    
One of the values that indicates the operating state of the gateway.

Constraints:
Length: 2 - 25

Parameters:
gatewayState One of the values that indicates the operating state of the gateway.
    public void setGatewayState(String gatewayState) {
        this. = gatewayState;
    }
    
    
One of the values that indicates the operating state of the gateway.

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

Constraints:
Length: 2 - 25

Parameters:
gatewayState One of the values that indicates the operating state of the gateway.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = gatewayState;
        return this;
    }

    
A NetworkInterface array that contains descriptions of the gateway network interfaces.

Returns:
A NetworkInterface array that contains descriptions of the gateway network interfaces.
        if ( == null) {
              .setAutoConstruct(true);
        }
        return ;
    }
    
    
A NetworkInterface array that contains descriptions of the gateway network interfaces.

Parameters:
gatewayNetworkInterfaces A NetworkInterface array that contains descriptions of the gateway network interfaces.
    public void setGatewayNetworkInterfaces(java.util.Collection<NetworkInterfacegatewayNetworkInterfaces) {
        if (gatewayNetworkInterfaces == null) {
            this. = null;
            return;
        }
        com.amazonaws.internal.ListWithAutoConstructFlag<NetworkInterfacegatewayNetworkInterfacesCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<NetworkInterface>(gatewayNetworkInterfaces.size());
        gatewayNetworkInterfacesCopy.addAll(gatewayNetworkInterfaces);
        this. = gatewayNetworkInterfacesCopy;
    }
    
    
A NetworkInterface array that contains descriptions of the gateway network interfaces.

NOTE: This method appends the values to the existing list (if any). Use setGatewayNetworkInterfaces(java.util.Collection) or withGatewayNetworkInterfaces(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:
gatewayNetworkInterfaces A NetworkInterface array that contains descriptions of the gateway network interfaces.
Returns:
A reference to this updated object so that method calls can be chained together.
        if (getGatewayNetworkInterfaces() == nullsetGatewayNetworkInterfaces(new java.util.ArrayList<NetworkInterface>(gatewayNetworkInterfaces.length));
        for (NetworkInterface value : gatewayNetworkInterfaces) {
            getGatewayNetworkInterfaces().add(value);
        }
        return this;
    }
    
    
A NetworkInterface array that contains descriptions of the gateway network interfaces.

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

Parameters:
gatewayNetworkInterfaces A NetworkInterface array that contains descriptions of the gateway network interfaces.
Returns:
A reference to this updated object so that method calls can be chained together.
        if (gatewayNetworkInterfaces == null) {
            this. = null;
        } else {
            com.amazonaws.internal.ListWithAutoConstructFlag<NetworkInterfacegatewayNetworkInterfacesCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<NetworkInterface>(gatewayNetworkInterfaces.size());
            gatewayNetworkInterfacesCopy.addAll(gatewayNetworkInterfaces);
            this. = gatewayNetworkInterfacesCopy;
        }
        return this;
    }

    
TBD

Constraints:
Length: 2 - 20

Returns:
TBD
    public String getGatewayType() {
        return ;
    }
    
    
TBD

Constraints:
Length: 2 - 20

Parameters:
gatewayType TBD
    public void setGatewayType(String gatewayType) {
        this. = gatewayType;
    }
    
    
TBD

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

Constraints:
Length: 2 - 20

Parameters:
gatewayType TBD
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = gatewayType;
        return this;
    }

    
The date at which an update to the gateway is available. This date is in the time zone of the gateway. If the gateway is not available for an update this field is not returned in the response.

Constraints:
Length: 1 - 25

Returns:
The date at which an update to the gateway is available. This date is in the time zone of the gateway. If the gateway is not available for an update this field is not returned in the response.
        return ;
    }
    
    
The date at which an update to the gateway is available. This date is in the time zone of the gateway. If the gateway is not available for an update this field is not returned in the response.

Constraints:
Length: 1 - 25

Parameters:
nextUpdateAvailabilityDate The date at which an update to the gateway is available. This date is in the time zone of the gateway. If the gateway is not available for an update this field is not returned in the response.
    public void setNextUpdateAvailabilityDate(String nextUpdateAvailabilityDate) {
        this. = nextUpdateAvailabilityDate;
    }
    
    
The date at which an update to the gateway is available. This date is in the time zone of the gateway. If the gateway is not available for an update this field is not returned in the response.

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

Constraints:
Length: 1 - 25

Parameters:
nextUpdateAvailabilityDate The date at which an update to the gateway is available. This date is in the time zone of the gateway. If the gateway is not available for an update this field is not returned in the response.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeGatewayInformationResult withNextUpdateAvailabilityDate(String nextUpdateAvailabilityDate) {
        this. = nextUpdateAvailabilityDate;
        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 (getGatewayARN() != nullsb.append("GatewayARN: " + getGatewayARN() + ",");
        if (getGatewayId() != nullsb.append("GatewayId: " + getGatewayId() + ",");
        if (getGatewayTimezone() != nullsb.append("GatewayTimezone: " + getGatewayTimezone() + ",");
        if (getGatewayState() != nullsb.append("GatewayState: " + getGatewayState() + ",");
        if (getGatewayNetworkInterfaces() != nullsb.append("GatewayNetworkInterfaces: " + getGatewayNetworkInterfaces() + ",");
        if (getGatewayType() != nullsb.append("GatewayType: " + getGatewayType() + ",");
        if (getNextUpdateAvailabilityDate() != nullsb.append("NextUpdateAvailabilityDate: " + getNextUpdateAvailabilityDate() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getGatewayARN() == null) ? 0 : getGatewayARN().hashCode()); 
        hashCode = prime * hashCode + ((getGatewayId() == null) ? 0 : getGatewayId().hashCode()); 
        hashCode = prime * hashCode + ((getGatewayTimezone() == null) ? 0 : getGatewayTimezone().hashCode()); 
        hashCode = prime * hashCode + ((getGatewayState() == null) ? 0 : getGatewayState().hashCode()); 
        hashCode = prime * hashCode + ((getGatewayNetworkInterfaces() == null) ? 0 : getGatewayNetworkInterfaces().hashCode()); 
        hashCode = prime * hashCode + ((getGatewayType() == null) ? 0 : getGatewayType().hashCode()); 
        hashCode = prime * hashCode + ((getNextUpdateAvailabilityDate() == null) ? 0 : getNextUpdateAvailabilityDate().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof DescribeGatewayInformationResult == falsereturn false;
        
        if (other.getGatewayARN() == null ^ this.getGatewayARN() == nullreturn false;
        if (other.getGatewayARN() != null && other.getGatewayARN().equals(this.getGatewayARN()) == falsereturn false
        if (other.getGatewayId() == null ^ this.getGatewayId() == nullreturn false;
        if (other.getGatewayId() != null && other.getGatewayId().equals(this.getGatewayId()) == falsereturn false
        if (other.getGatewayTimezone() == null ^ this.getGatewayTimezone() == nullreturn false;
        if (other.getGatewayTimezone() != null && other.getGatewayTimezone().equals(this.getGatewayTimezone()) == falsereturn false
        if (other.getGatewayState() == null ^ this.getGatewayState() == nullreturn false;
        if (other.getGatewayState() != null && other.getGatewayState().equals(this.getGatewayState()) == falsereturn false
        if (other.getGatewayNetworkInterfaces() == null ^ this.getGatewayNetworkInterfaces() == nullreturn false;
        if (other.getGatewayNetworkInterfaces() != null && other.getGatewayNetworkInterfaces().equals(this.getGatewayNetworkInterfaces()) == falsereturn false
        if (other.getGatewayType() == null ^ this.getGatewayType() == nullreturn false;
        if (other.getGatewayType() != null && other.getGatewayType().equals(this.getGatewayType()) == falsereturn false
        if (other.getNextUpdateAvailabilityDate() == null ^ this.getNextUpdateAvailabilityDate() == nullreturn false;
        if (other.getNextUpdateAvailabilityDate() != null && other.getNextUpdateAvailabilityDate().equals(this.getNextUpdateAvailabilityDate()) == falsereturn false
        return true;
    }
    
    @Override
        try {
            return (DescribeGatewayInformationResultsuper.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