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 ApplyPendingMaintenanceAction operation.

Applies a pending maintenance action to a resource (for example, a DB instance).

 
 public class ApplyPendingMaintenanceActionRequest extends AmazonWebServiceRequest implements SerializableCloneable {

    
The ARN of the resource that the pending maintenance action applies to.
 
     private String resourceIdentifier;

    
The pending maintenance action to apply to this resource.
 
     private String applyAction;

    
A value that specifies the type of opt-in request, or undoes an opt-in request. An opt-in request of type immediate cannot be undone.

Valid values:

  • immediate - Apply the maintenance action immediately.
  • next-maintenance - Apply the maintenance action during the next maintenance window for the resource.
  • undo-opt-in - Cancel any existing next-maintenance opt-in requests.
 
     private String optInType;

    
The ARN of the resource that the pending maintenance action applies to.

Returns:
The ARN of the resource that the pending maintenance action applies to.
 
     public String getResourceIdentifier() {
         return ;
     }
    
    
The ARN of the resource that the pending maintenance action applies to.

Parameters:
resourceIdentifier The ARN of the resource that the pending maintenance action applies to.
 
     public void setResourceIdentifier(String resourceIdentifier) {
         this. = resourceIdentifier;
     }
    
    
The ARN of the resource that the pending maintenance action applies to.

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

Parameters:
resourceIdentifier The ARN of the resource that the pending maintenance action applies to.
Returns:
A reference to this updated object so that method calls can be chained together.
 
     public ApplyPendingMaintenanceActionRequest withResourceIdentifier(String resourceIdentifier) {
         this. = resourceIdentifier;
         return this;
     }

    
The pending maintenance action to apply to this resource.

Returns:
The pending maintenance action to apply to this resource.
 
     public String getApplyAction() {
        return ;
    }
    
    
The pending maintenance action to apply to this resource.

Parameters:
applyAction The pending maintenance action to apply to this resource.
    public void setApplyAction(String applyAction) {
        this. = applyAction;
    }
    
    
The pending maintenance action to apply to this resource.

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

Parameters:
applyAction The pending maintenance action to apply to this resource.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = applyAction;
        return this;
    }

    
A value that specifies the type of opt-in request, or undoes an opt-in request. An opt-in request of type immediate cannot be undone.

Valid values:

  • immediate - Apply the maintenance action immediately.
  • next-maintenance - Apply the maintenance action during the next maintenance window for the resource.
  • undo-opt-in - Cancel any existing next-maintenance opt-in requests.

Returns:
A value that specifies the type of opt-in request, or undoes an opt-in request. An opt-in request of type immediate cannot be undone.

Valid values:

  • immediate - Apply the maintenance action immediately.
  • next-maintenance - Apply the maintenance action during the next maintenance window for the resource.
  • undo-opt-in - Cancel any existing next-maintenance opt-in requests.
    public String getOptInType() {
        return ;
    }
    
    
A value that specifies the type of opt-in request, or undoes an opt-in request. An opt-in request of type immediate cannot be undone.

Valid values:

  • immediate - Apply the maintenance action immediately.
  • next-maintenance - Apply the maintenance action during the next maintenance window for the resource.
  • undo-opt-in - Cancel any existing next-maintenance opt-in requests.

Parameters:
optInType A value that specifies the type of opt-in request, or undoes an opt-in request. An opt-in request of type immediate cannot be undone.

Valid values:

  • immediate - Apply the maintenance action immediately.
  • next-maintenance - Apply the maintenance action during the next maintenance window for the resource.
  • undo-opt-in - Cancel any existing next-maintenance opt-in requests.
    public void setOptInType(String optInType) {
        this. = optInType;
    }
    
    
A value that specifies the type of opt-in request, or undoes an opt-in request. An opt-in request of type immediate cannot be undone.

Valid values:

  • immediate - Apply the maintenance action immediately.
  • next-maintenance - Apply the maintenance action during the next maintenance window for the resource.
  • undo-opt-in - Cancel any existing next-maintenance opt-in requests.

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

Parameters:
optInType A value that specifies the type of opt-in request, or undoes an opt-in request. An opt-in request of type immediate cannot be undone.

Valid values:

  • immediate - Apply the maintenance action immediately.
  • next-maintenance - Apply the maintenance action during the next maintenance window for the resource.
  • undo-opt-in - Cancel any existing next-maintenance opt-in requests.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = optInType;
        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 (getResourceIdentifier() != nullsb.append("ResourceIdentifier: " + getResourceIdentifier() + ",");
        if (getApplyAction() != nullsb.append("ApplyAction: " + getApplyAction() + ",");
        if (getOptInType() != nullsb.append("OptInType: " + getOptInType() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getResourceIdentifier() == null) ? 0 : getResourceIdentifier().hashCode()); 
        hashCode = prime * hashCode + ((getApplyAction() == null) ? 0 : getApplyAction().hashCode()); 
        hashCode = prime * hashCode + ((getOptInType() == null) ? 0 : getOptInType().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof ApplyPendingMaintenanceActionRequest == falsereturn false;
        
        if (other.getResourceIdentifier() == null ^ this.getResourceIdentifier() == nullreturn false;
        if (other.getResourceIdentifier() != null && other.getResourceIdentifier().equals(this.getResourceIdentifier()) == falsereturn false
        if (other.getApplyAction() == null ^ this.getApplyAction() == nullreturn false;
        if (other.getApplyAction() != null && other.getApplyAction().equals(this.getApplyAction()) == falsereturn false
        if (other.getOptInType() == null ^ this.getOptInType() == nullreturn false;
        if (other.getOptInType() != null && other.getOptInType().equals(this.getOptInType()) == falsereturn false
        return true;
    }
    
    @Override
        
            return (ApplyPendingMaintenanceActionRequestsuper.clone();
    }
}
    
New to GrepCode? Check out our FAQ X