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.rds.model;
 
 
Container for the parameters to the ModifyOptionGroup operation.

Modifies an existing option group.

 
 public class ModifyOptionGroupRequest extends AmazonWebServiceRequest implements SerializableCloneable {

    
The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, cannot be removed from an option group, and that option group cannot be removed from a DB instance once it is associated with a DB instance

 
     private String optionGroupName;

    
Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.
 
Options in this list are removed from the option group.
 
Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.
 
     private Boolean applyImmediately;

    
The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, cannot be removed from an option group, and that option group cannot be removed from a DB instance once it is associated with a DB instance

Returns:
The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, cannot be removed from an option group, and that option group cannot be removed from a DB instance once it is associated with a DB instance

 
     public String getOptionGroupName() {
         return ;
     }
    
    
The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, cannot be removed from an option group, and that option group cannot be removed from a DB instance once it is associated with a DB instance

Parameters:
optionGroupName The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, cannot be removed from an option group, and that option group cannot be removed from a DB instance once it is associated with a DB instance

 
     public void setOptionGroupName(String optionGroupName) {
         this. = optionGroupName;
     }
    
    
The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, cannot be removed from an option group, and that option group cannot be removed from a DB instance once it is associated with a DB instance

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

Parameters:
optionGroupName The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, cannot be removed from an option group, and that option group cannot be removed from a DB instance once it is associated with a DB instance

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

    
Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.

Returns:
Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.
        if ( == null) {
              .setAutoConstruct(true);
        }
        return ;
    }
    
    
Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.

Parameters:
optionsToInclude Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.
    public void setOptionsToInclude(java.util.Collection<OptionConfigurationoptionsToInclude) {
        if (optionsToInclude == null) {
            this. = null;
            return;
        }
        optionsToIncludeCopy.addAll(optionsToInclude);
        this. = optionsToIncludeCopy;
    }
    
    
Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.

NOTE: This method appends the values to the existing list (if any). Use setOptionsToInclude(java.util.Collection) or withOptionsToInclude(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:
optionsToInclude Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.
Returns:
A reference to this updated object so that method calls can be chained together.
    public ModifyOptionGroupRequest withOptionsToInclude(OptionConfiguration... optionsToInclude) {
        if (getOptionsToInclude() == nullsetOptionsToInclude(new java.util.ArrayList<OptionConfiguration>(optionsToInclude.length));
        for (OptionConfiguration value : optionsToInclude) {
            getOptionsToInclude().add(value);
        }
        return this;
    }
    
    
Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.

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

Parameters:
optionsToInclude Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.
Returns:
A reference to this updated object so that method calls can be chained together.
        if (optionsToInclude == null) {
            this. = null;
        } else {
            optionsToIncludeCopy.addAll(optionsToInclude);
            this. = optionsToIncludeCopy;
        }
        return this;
    }

    
Options in this list are removed from the option group.

Returns:
Options in this list are removed from the option group.
    public java.util.List<StringgetOptionsToRemove() {
        if ( == null) {
               = new com.amazonaws.internal.ListWithAutoConstructFlag<String>();
              .setAutoConstruct(true);
        }
        return ;
    }
    
    
Options in this list are removed from the option group.

Parameters:
optionsToRemove Options in this list are removed from the option group.
    public void setOptionsToRemove(java.util.Collection<StringoptionsToRemove) {
        if (optionsToRemove == null) {
            this. = null;
            return;
        }
        com.amazonaws.internal.ListWithAutoConstructFlag<StringoptionsToRemoveCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<String>(optionsToRemove.size());
        optionsToRemoveCopy.addAll(optionsToRemove);
        this. = optionsToRemoveCopy;
    }
    
    
Options in this list are removed from the option group.

NOTE: This method appends the values to the existing list (if any). Use setOptionsToRemove(java.util.Collection) or withOptionsToRemove(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:
optionsToRemove Options in this list are removed from the option group.
Returns:
A reference to this updated object so that method calls can be chained together.
    public ModifyOptionGroupRequest withOptionsToRemove(String... optionsToRemove) {
        if (getOptionsToRemove() == nullsetOptionsToRemove(new java.util.ArrayList<String>(optionsToRemove.length));
        for (String value : optionsToRemove) {
            getOptionsToRemove().add(value);
        }
        return this;
    }
    
    
Options in this list are removed from the option group.

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

Parameters:
optionsToRemove Options in this list are removed from the option group.
Returns:
A reference to this updated object so that method calls can be chained together.
        if (optionsToRemove == null) {
            this. = null;
        } else {
            com.amazonaws.internal.ListWithAutoConstructFlag<StringoptionsToRemoveCopy = new com.amazonaws.internal.ListWithAutoConstructFlag<String>(optionsToRemove.size());
            optionsToRemoveCopy.addAll(optionsToRemove);
            this. = optionsToRemoveCopy;
        }
        return this;
    }

    
Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.

Returns:
Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.
    public Boolean isApplyImmediately() {
        return ;
    }
    
    
Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.

Parameters:
applyImmediately Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.
    public void setApplyImmediately(Boolean applyImmediately) {
        this. = applyImmediately;
    }
    
    
Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.

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

Parameters:
applyImmediately Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.
Returns:
A reference to this updated object so that method calls can be chained together.
    public ModifyOptionGroupRequest withApplyImmediately(Boolean applyImmediately) {
        this. = applyImmediately;
        return this;
    }

    
Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.

Returns:
Indicates whether the changes should be applied immediately, or during the next maintenance window for each instance associated with the option group.
    public Boolean getApplyImmediately() {
        return ;
    }

    
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 (getOptionGroupName() != nullsb.append("OptionGroupName: " + getOptionGroupName() + ",");
        if (getOptionsToInclude() != nullsb.append("OptionsToInclude: " + getOptionsToInclude() + ",");
        if (getOptionsToRemove() != nullsb.append("OptionsToRemove: " + getOptionsToRemove() + ",");
        if (isApplyImmediately() != nullsb.append("ApplyImmediately: " + isApplyImmediately() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getOptionGroupName() == null) ? 0 : getOptionGroupName().hashCode()); 
        hashCode = prime * hashCode + ((getOptionsToInclude() == null) ? 0 : getOptionsToInclude().hashCode()); 
        hashCode = prime * hashCode + ((getOptionsToRemove() == null) ? 0 : getOptionsToRemove().hashCode()); 
        hashCode = prime * hashCode + ((isApplyImmediately() == null) ? 0 : isApplyImmediately().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof ModifyOptionGroupRequest == falsereturn false;
        ModifyOptionGroupRequest other = (ModifyOptionGroupRequest)obj;
        
        if (other.getOptionGroupName() == null ^ this.getOptionGroupName() == nullreturn false;
        if (other.getOptionGroupName() != null && other.getOptionGroupName().equals(this.getOptionGroupName()) == falsereturn false
        if (other.getOptionsToInclude() == null ^ this.getOptionsToInclude() == nullreturn false;
        if (other.getOptionsToInclude() != null && other.getOptionsToInclude().equals(this.getOptionsToInclude()) == falsereturn false
        if (other.getOptionsToRemove() == null ^ this.getOptionsToRemove() == nullreturn false;
        if (other.getOptionsToRemove() != null && other.getOptionsToRemove().equals(this.getOptionsToRemove()) == falsereturn false
        if (other.isApplyImmediately() == null ^ this.isApplyImmediately() == nullreturn false;
        if (other.isApplyImmediately() != null && other.isApplyImmediately().equals(this.isApplyImmediately()) == falsereturn false
        return true;
    }
    
    @Override
    public ModifyOptionGroupRequest clone() {
        
            return (ModifyOptionGroupRequestsuper.clone();
    }
}
    
New to GrepCode? Check out our FAQ X