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

The output for the GetResourceConfigHistory action.

 
 public class GetResourceConfigHistoryResult implements SerializableCloneable {

    
A list that contains the configuration history of one or more resources.
 
A token used for pagination of results.
 
     private String nextToken;

    
A list that contains the configuration history of one or more resources.

Returns:
A list that contains the configuration history of one or more resources.
 
         if ( == null) {
               .setAutoConstruct(true);
         }
         return ;
     }
    
    
A list that contains the configuration history of one or more resources.

Parameters:
configurationItems A list that contains the configuration history of one or more resources.
 
     public void setConfigurationItems(java.util.Collection<ConfigurationItemconfigurationItems) {
         if (configurationItems == null) {
             this. = null;
             return;
         }
         configurationItemsCopy.addAll(configurationItems);
         this. = configurationItemsCopy;
     }
    
    
A list that contains the configuration history of one or more resources.

NOTE: This method appends the values to the existing list (if any). Use setConfigurationItems(java.util.Collection) or withConfigurationItems(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:
configurationItems A list that contains the configuration history of one or more resources.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public GetResourceConfigHistoryResult withConfigurationItems(ConfigurationItem... configurationItems) {
         if (getConfigurationItems() == nullsetConfigurationItems(new java.util.ArrayList<ConfigurationItem>(configurationItems.length));
         for (ConfigurationItem value : configurationItems) {
             getConfigurationItems().add(value);
         }
         return this;
     }
    
    
A list that contains the configuration history of one or more resources.

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

Parameters:
configurationItems A list that contains the configuration history of one or more resources.
Returns:
A reference to this updated object so that method calls can be chained together.
        if (configurationItems == null) {
            this. = null;
        } else {
            com.amazonaws.internal.ListWithAutoConstructFlag<ConfigurationItemconfigurationItemsCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<ConfigurationItem>(configurationItems.size());
            configurationItemsCopy.addAll(configurationItems);
            this. = configurationItemsCopy;
        }
        return this;
    }

    
A token used for pagination of results.

Returns:
A token used for pagination of results.
    public String getNextToken() {
        return ;
    }
    
    
A token used for pagination of results.

Parameters:
nextToken A token used for pagination of results.
    public void setNextToken(String nextToken) {
        this. = nextToken;
    }
    
    
A token used for pagination of results.

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

Parameters:
nextToken A token used for pagination of results.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = nextToken;
        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 (getConfigurationItems() != nullsb.append("ConfigurationItems: " + getConfigurationItems() + ",");
        if (getNextToken() != nullsb.append("NextToken: " + getNextToken() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getConfigurationItems() == null) ? 0 : getConfigurationItems().hashCode()); 
        hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof GetResourceConfigHistoryResult == falsereturn false;
        
        if (other.getConfigurationItems() == null ^ this.getConfigurationItems() == nullreturn false;
        if (other.getConfigurationItems() != null && other.getConfigurationItems().equals(this.getConfigurationItems()) == falsereturn false
        if (other.getNextToken() == null ^ this.getNextToken() == nullreturn false;
        if (other.getNextToken() != null && other.getNextToken().equals(this.getNextToken()) == falsereturn false
        return true;
    }
    
    @Override
        try {
            return (GetResourceConfigHistoryResultsuper.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