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

Contains information about a resource identified by a Trusted Advisor check.

 
 public class TrustedAdvisorResourceDetail implements SerializableCloneable {

    
The status code for the resource identified in the Trusted Advisor check.
 
     private String status;

    
The AWS region in which the identified resource is located.
 
     private String region;

    
The unique identifier for the identified resource.
 
     private String resourceId;

    
Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.
 
     private Boolean isSuppressed;

    
Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.
 
The status code for the resource identified in the Trusted Advisor check.

Returns:
The status code for the resource identified in the Trusted Advisor check.
 
     public String getStatus() {
         return ;
     }
    
    
The status code for the resource identified in the Trusted Advisor check.

Parameters:
status The status code for the resource identified in the Trusted Advisor check.
 
     public void setStatus(String status) {
         this. = status;
     }
    
    
The status code for the resource identified in the Trusted Advisor check.

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

Parameters:
status The status code for the resource identified in the Trusted Advisor check.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public TrustedAdvisorResourceDetail withStatus(String status) {
         this. = status;
         return this;
     }

    
The AWS region in which the identified resource is located.

Returns:
The AWS region in which the identified resource is located.
    public String getRegion() {
        return ;
    }
    
    
The AWS region in which the identified resource is located.

Parameters:
region The AWS region in which the identified resource is located.
    public void setRegion(String region) {
        this. = region;
    }
    
    
The AWS region in which the identified resource is located.

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

Parameters:
region The AWS region in which the identified resource is located.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = region;
        return this;
    }

    
The unique identifier for the identified resource.

Returns:
The unique identifier for the identified resource.
    public String getResourceId() {
        return ;
    }
    
    
The unique identifier for the identified resource.

Parameters:
resourceId The unique identifier for the identified resource.
    public void setResourceId(String resourceId) {
        this. = resourceId;
    }
    
    
The unique identifier for the identified resource.

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

Parameters:
resourceId The unique identifier for the identified resource.
Returns:
A reference to this updated object so that method calls can be chained together.
    public TrustedAdvisorResourceDetail withResourceId(String resourceId) {
        this. = resourceId;
        return this;
    }

    
Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.

Returns:
Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.
    public Boolean isSuppressed() {
        return ;
    }
    
    
Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.

Parameters:
isSuppressed Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.
    public void setIsSuppressed(Boolean isSuppressed) {
        this. = isSuppressed;
    }
    
    
Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.

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

Parameters:
isSuppressed Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.
Returns:
A reference to this updated object so that method calls can be chained together.
    public TrustedAdvisorResourceDetail withIsSuppressed(Boolean isSuppressed) {
        this. = isSuppressed;
        return this;
    }

    
Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.

Returns:
Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.
    public Boolean getIsSuppressed() {
        return ;
    }

    
Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.

Returns:
Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.
    public java.util.List<StringgetMetadata() {
        if ( == null) {
               = new com.amazonaws.internal.ListWithAutoConstructFlag<String>();
              .setAutoConstruct(true);
        }
        return ;
    }
    
    
Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.

Parameters:
metadata Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.
    public void setMetadata(java.util.Collection<Stringmetadata) {
        if (metadata == null) {
            this. = null;
            return;
        }
        metadataCopy.addAll(metadata);
        this. = metadataCopy;
    }
    
    
Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.

NOTE: This method appends the values to the existing list (if any). Use setMetadata(java.util.Collection) or withMetadata(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:
metadata Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.
Returns:
A reference to this updated object so that method calls can be chained together.
    public TrustedAdvisorResourceDetail withMetadata(String... metadata) {
        if (getMetadata() == nullsetMetadata(new java.util.ArrayList<String>(metadata.length));
        for (String value : metadata) {
            getMetadata().add(value);
        }
        return this;
    }
    
    
Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.

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

Parameters:
metadata Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.
Returns:
A reference to this updated object so that method calls can be chained together.
        if (metadata == null) {
            this. = null;
        } else {
            metadataCopy.addAll(metadata);
            this. = metadataCopy;
        }
        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 (getStatus() != nullsb.append("Status: " + getStatus() + ",");
        if (getRegion() != nullsb.append("Region: " + getRegion() + ",");
        if (getResourceId() != nullsb.append("ResourceId: " + getResourceId() + ",");
        if (isSuppressed() != nullsb.append("IsSuppressed: " + isSuppressed() + ",");
        if (getMetadata() != nullsb.append("Metadata: " + getMetadata() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); 
        hashCode = prime * hashCode + ((getRegion() == null) ? 0 : getRegion().hashCode()); 
        hashCode = prime * hashCode + ((getResourceId() == null) ? 0 : getResourceId().hashCode()); 
        hashCode = prime * hashCode + ((isSuppressed() == null) ? 0 : isSuppressed().hashCode()); 
        hashCode = prime * hashCode + ((getMetadata() == null) ? 0 : getMetadata().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof TrustedAdvisorResourceDetail == falsereturn false;
        
        if (other.getStatus() == null ^ this.getStatus() == nullreturn false;
        if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == falsereturn false
        if (other.getRegion() == null ^ this.getRegion() == nullreturn false;
        if (other.getRegion() != null && other.getRegion().equals(this.getRegion()) == falsereturn false
        if (other.getResourceId() == null ^ this.getResourceId() == nullreturn false;
        if (other.getResourceId() != null && other.getResourceId().equals(this.getResourceId()) == falsereturn false
        if (other.isSuppressed() == null ^ this.isSuppressed() == nullreturn false;
        if (other.isSuppressed() != null && other.isSuppressed().equals(this.isSuppressed()) == falsereturn false
        if (other.getMetadata() == null ^ this.getMetadata() == nullreturn false;
        if (other.getMetadata() != null && other.getMetadata().equals(this.getMetadata()) == falsereturn false
        return true;
    }
    
    @Override
        try {
            return (TrustedAdvisorResourceDetailsuper.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