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

You can update an event source mapping. This is useful if you want to change the parameters of the existing mapping without losing your position in the stream. You can change which function will receive the stream records, but to change the stream itself, you must create a new mapping.

This operation requires permission for the lambda:UpdateEventSourceMapping action.

 
 public class UpdateEventSourceMappingRequest extends AmazonWebServiceRequest implements SerializableCloneable {

    
The event source mapping identifier.
 
     private String uUID;

    
The Lambda function to which you want the stream records sent.

You can specify an unqualified function name (for example, "Thumbnail") or you can specify Amazon Resource Name (ARN) of the function (for example, "arn:aws:lambda:us-west-2:account-id:function:ThumbNail"). AWS Lambda also allows you to specify only the account ID qualifier (for example, "account-id:Thumbnail"). Note that the length constraint applies only to the ARN. If you specify only the function name, it is limited to 64 character in length.

Constraints:
Length: 1 - 111
Pattern: (arn:aws:lambda:)?([a-z]{2}-[a-z]+-\d{1}:)?(\d{12}:)?(function:)?([a-zA-Z0-9-_]+)

 
     private String functionName;

    
Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.
 
     private Boolean enabled;

    
The maximum number of stream records that can be sent to your Lambda function for a single invocation.

Constraints:
Range: 1 - 10000

 
     private Integer batchSize;

    
The event source mapping identifier.

Returns:
The event source mapping identifier.
 
     public String getUUID() {
         return ;
     }
    
    
The event source mapping identifier.

Parameters:
uUID The event source mapping identifier.
 
     public void setUUID(String uUID) {
         this. = uUID;
     }
    
    
The event source mapping identifier.

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

Parameters:
uUID The event source mapping identifier.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = uUID;
        return this;
    }

    
The Lambda function to which you want the stream records sent.

You can specify an unqualified function name (for example, "Thumbnail") or you can specify Amazon Resource Name (ARN) of the function (for example, "arn:aws:lambda:us-west-2:account-id:function:ThumbNail"). AWS Lambda also allows you to specify only the account ID qualifier (for example, "account-id:Thumbnail"). Note that the length constraint applies only to the ARN. If you specify only the function name, it is limited to 64 character in length.

Constraints:
Length: 1 - 111
Pattern: (arn:aws:lambda:)?([a-z]{2}-[a-z]+-\d{1}:)?(\d{12}:)?(function:)?([a-zA-Z0-9-_]+)

Returns:
The Lambda function to which you want the stream records sent.

You can specify an unqualified function name (for example, "Thumbnail") or you can specify Amazon Resource Name (ARN) of the function (for example, "arn:aws:lambda:us-west-2:account-id:function:ThumbNail"). AWS Lambda also allows you to specify only the account ID qualifier (for example, "account-id:Thumbnail"). Note that the length constraint applies only to the ARN. If you specify only the function name, it is limited to 64 character in length.

    public String getFunctionName() {
        return ;
    }
    
    
The Lambda function to which you want the stream records sent.

You can specify an unqualified function name (for example, "Thumbnail") or you can specify Amazon Resource Name (ARN) of the function (for example, "arn:aws:lambda:us-west-2:account-id:function:ThumbNail"). AWS Lambda also allows you to specify only the account ID qualifier (for example, "account-id:Thumbnail"). Note that the length constraint applies only to the ARN. If you specify only the function name, it is limited to 64 character in length.

Constraints:
Length: 1 - 111
Pattern: (arn:aws:lambda:)?([a-z]{2}-[a-z]+-\d{1}:)?(\d{12}:)?(function:)?([a-zA-Z0-9-_]+)

Parameters:
functionName The Lambda function to which you want the stream records sent.

You can specify an unqualified function name (for example, "Thumbnail") or you can specify Amazon Resource Name (ARN) of the function (for example, "arn:aws:lambda:us-west-2:account-id:function:ThumbNail"). AWS Lambda also allows you to specify only the account ID qualifier (for example, "account-id:Thumbnail"). Note that the length constraint applies only to the ARN. If you specify only the function name, it is limited to 64 character in length.

    public void setFunctionName(String functionName) {
        this. = functionName;
    }
    
    
The Lambda function to which you want the stream records sent.

You can specify an unqualified function name (for example, "Thumbnail") or you can specify Amazon Resource Name (ARN) of the function (for example, "arn:aws:lambda:us-west-2:account-id:function:ThumbNail"). AWS Lambda also allows you to specify only the account ID qualifier (for example, "account-id:Thumbnail"). Note that the length constraint applies only to the ARN. If you specify only the function name, it is limited to 64 character in length.

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

Constraints:
Length: 1 - 111
Pattern: (arn:aws:lambda:)?([a-z]{2}-[a-z]+-\d{1}:)?(\d{12}:)?(function:)?([a-zA-Z0-9-_]+)

Parameters:
functionName The Lambda function to which you want the stream records sent.

You can specify an unqualified function name (for example, "Thumbnail") or you can specify Amazon Resource Name (ARN) of the function (for example, "arn:aws:lambda:us-west-2:account-id:function:ThumbNail"). AWS Lambda also allows you to specify only the account ID qualifier (for example, "account-id:Thumbnail"). Note that the length constraint applies only to the ARN. If you specify only the function name, it is limited to 64 character in length.

Returns:
A reference to this updated object so that method calls can be chained together.
        this. = functionName;
        return this;
    }

    
Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.

Returns:
Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.
    public Boolean isEnabled() {
        return ;
    }
    
    
Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.

Parameters:
enabled Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.
    public void setEnabled(Boolean enabled) {
        this. = enabled;
    }
    
    
Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.

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

Parameters:
enabled Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = enabled;
        return this;
    }

    
Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.

Returns:
Specifies whether AWS Lambda should actively poll the stream or not. If disabled, AWS Lambda will not poll the stream.
    public Boolean getEnabled() {
        return ;
    }

    
The maximum number of stream records that can be sent to your Lambda function for a single invocation.

Constraints:
Range: 1 - 10000

Returns:
The maximum number of stream records that can be sent to your Lambda function for a single invocation.
    public Integer getBatchSize() {
        return ;
    }
    
    
The maximum number of stream records that can be sent to your Lambda function for a single invocation.

Constraints:
Range: 1 - 10000

Parameters:
batchSize The maximum number of stream records that can be sent to your Lambda function for a single invocation.
    public void setBatchSize(Integer batchSize) {
        this. = batchSize;
    }
    
    
The maximum number of stream records that can be sent to your Lambda function for a single invocation.

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

Constraints:
Range: 1 - 10000

Parameters:
batchSize The maximum number of stream records that can be sent to your Lambda function for a single invocation.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = batchSize;
        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 (getUUID() != nullsb.append("UUID: " + getUUID() + ",");
        if (getFunctionName() != nullsb.append("FunctionName: " + getFunctionName() + ",");
        if (isEnabled() != nullsb.append("Enabled: " + isEnabled() + ",");
        if (getBatchSize() != nullsb.append("BatchSize: " + getBatchSize() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getUUID() == null) ? 0 : getUUID().hashCode()); 
        hashCode = prime * hashCode + ((getFunctionName() == null) ? 0 : getFunctionName().hashCode()); 
        hashCode = prime * hashCode + ((isEnabled() == null) ? 0 : isEnabled().hashCode()); 
        hashCode = prime * hashCode + ((getBatchSize() == null) ? 0 : getBatchSize().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof UpdateEventSourceMappingRequest == falsereturn false;
        
        if (other.getUUID() == null ^ this.getUUID() == nullreturn false;
        if (other.getUUID() != null && other.getUUID().equals(this.getUUID()) == falsereturn false
        if (other.getFunctionName() == null ^ this.getFunctionName() == nullreturn false;
        if (other.getFunctionName() != null && other.getFunctionName().equals(this.getFunctionName()) == falsereturn false
        if (other.isEnabled() == null ^ this.isEnabled() == nullreturn false;
        if (other.isEnabled() != null && other.isEnabled().equals(this.isEnabled()) == falsereturn false
        if (other.getBatchSize() == null ^ this.getBatchSize() == nullreturn false;
        if (other.getBatchSize() != null && other.getBatchSize().equals(this.getBatchSize()) == falsereturn false
        return true;
    }
    
    @Override
        
            return (UpdateEventSourceMappingRequestsuper.clone();
    }
}
    
New to GrepCode? Check out our FAQ X