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

Signer
 
 public class Signer {
 
     private String awsAccountNumber;
 
     private String self;
 
     private java.util.List<StringkeyPairIds;

    
Default constructor for a new Signer object. Callers should use the setter or fluent setter (with...) methods to initialize this object after creating it.
 
     public Signer() {}
    
    
Returns the value of the AwsAccountNumber property for this object.

Returns:
The value of the AwsAccountNumber property for this object.
 
     public String getAwsAccountNumber() {
         return ;
     }
    
    
Sets the value of the AwsAccountNumber property for this object.

Parameters:
awsAccountNumber The new value for the AwsAccountNumber property for this object.
 
     public void setAwsAccountNumber(String awsAccountNumber) {
         this. = awsAccountNumber;
     }
    
    
Sets the value of the AwsAccountNumber property for this object.

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

Parameters:
awsAccountNumber The new value for the AwsAccountNumber property for this object.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public Signer withAwsAccountNumber(String awsAccountNumber) {
         this. = awsAccountNumber;
         return this;
     }
    
    
    
Returns the value of the Self property for this object.

Returns:
The value of the Self property for this object.
 
     public String getSelf() {
         return ;
     }
    
    
Sets the value of the Self property for this object.

Parameters:
self The new value for the Self property for this object.
 
     public void setSelf(String self) {
         this. = self;
     }
    
    
Sets the value of the Self property for this object.

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

Parameters:
self The new value for the Self property for this object.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public Signer withSelf(String self) {
         this. = self;
         return this;
     }
    
    
    
Returns the value of the KeyPairIds property for this object.

Returns:
The value of the KeyPairIds property for this object.
    public java.util.List<StringgetKeyPairIds() {
        
        if ( == null) {
             = new java.util.ArrayList<String>();
        }
        return ;
    }
    
    
Sets the value of the KeyPairIds property for this object.

Parameters:
keyPairIds The new value for the KeyPairIds property for this object.
    public void setKeyPairIds(java.util.Collection<StringkeyPairIds) {
        if (keyPairIds == null) {
            this. = null;
            return;
        }
        java.util.List<StringkeyPairIdsCopy = new java.util.ArrayList<String>(keyPairIds.size());
        keyPairIdsCopy.addAll(keyPairIds);
        this. = keyPairIdsCopy;
    }
    
    
Sets the value of the KeyPairIds property for this object.

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

Parameters:
keyPairIds The new value for the KeyPairIds property for this object.
Returns:
A reference to this updated object so that method calls can be chained together.
    public Signer withKeyPairIds(String... keyPairIds) {
        if (getKeyPairIds() == nullsetKeyPairIds(new java.util.ArrayList<String>(keyPairIds.length));
        for (String value : keyPairIds) {
            getKeyPairIds().add(value);
        }
        return this;
    }
    
    
Sets the value of the KeyPairIds property for this object.

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

Parameters:
keyPairIds The new value for the KeyPairIds property for this object.
Returns:
A reference to this updated object so that method calls can be chained together.
    public Signer withKeyPairIds(java.util.Collection<StringkeyPairIds) {
        if (keyPairIds == null) {
            this. = null;
        } else {
            java.util.List<StringkeyPairIdsCopy = new java.util.ArrayList<String>(keyPairIds.size());
            keyPairIdsCopy.addAll(keyPairIds);
            this. = keyPairIdsCopy;
        }
        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 ( != nullsb.append("AwsAccountNumber: " +  + ", ");
        if ( != nullsb.append("Self: " +  + ", ");
        if ( != nullsb.append("KeyPairIds: " +  + ", ");
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getAwsAccountNumber() == null) ? 0 : getAwsAccountNumber().hashCode()); 
        hashCode = prime * hashCode + ((getSelf() == null) ? 0 : getSelf().hashCode()); 
        hashCode = prime * hashCode + ((getKeyPairIds() == null) ? 0 : getKeyPairIds().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
    
        if (obj instanceof Signer == falsereturn false;
        Signer other = (Signer)obj;
        
        if (other.getAwsAccountNumber() == null ^ this.getAwsAccountNumber() == nullreturn false;
        if (other.getAwsAccountNumber() != null && other.getAwsAccountNumber().equals(this.getAwsAccountNumber()) == falsereturn false
        if (other.getSelf() == null ^ this.getSelf() == nullreturn false;
        if (other.getSelf() != null && other.getSelf().equals(this.getSelf()) == falsereturn false
        if (other.getKeyPairIds() == null ^ this.getKeyPairIds() == nullreturn false;
        if (other.getKeyPairIds() != null && other.getKeyPairIds().equals(this.getKeyPairIds()) == falsereturn false
        return true;
    }
    
}
    
New to GrepCode? Check out our FAQ X