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

Returns list of event descriptions matching criteria up to the last 6 weeks.

NOTE: This action returns the most recent 1,000 events from the specified NextToken.

 
 public class DescribeEventsRequest extends AmazonWebServiceRequest implements SerializableCloneable {

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.

Constraints:
Length: 1 - 100

 
     private String applicationName;

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.

Constraints:
Length: 1 - 100

 
     private String versionLabel;

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.

Constraints:
Length: 1 - 100

 
     private String templateName;

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.
 
     private String environmentId;

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

Constraints:
Length: 4 - 23

 
     private String environmentName;

    
If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.
 
     private String requestId;

    
If specified, limits the events returned from this call to include only those with the specified severity or higher.

Constraints:
Allowed Values: TRACE, DEBUG, INFO, WARN, ERROR, FATAL

 
     private String severity;

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.
 
     private java.util.Date startTime;

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.
    private java.util.Date endTime;

    
Specifies the maximum number of events that can be returned, beginning with the most recent event.

Constraints:
Range: 1 - 1000

    private Integer maxRecords;

    
Pagination token. If specified, the events return the next batch of results.
    private String nextToken;

    
Default constructor for a new DescribeEventsRequest object. Callers should use the setter or fluent setter (with...) methods to initialize this object after creating it.
    public DescribeEventsRequest() {}
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.

Constraints:
Length: 1 - 100

Returns:
If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.
    public String getApplicationName() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.

Constraints:
Length: 1 - 100

Parameters:
applicationName If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.
    public void setApplicationName(String applicationName) {
        this. = applicationName;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.

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

Constraints:
Length: 1 - 100

Parameters:
applicationName If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withApplicationName(String applicationName) {
        this. = applicationName;
        return this;
    }

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.

Constraints:
Length: 1 - 100

Returns:
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.
    public String getVersionLabel() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.

Constraints:
Length: 1 - 100

Parameters:
versionLabel If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.
    public void setVersionLabel(String versionLabel) {
        this. = versionLabel;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.

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

Constraints:
Length: 1 - 100

Parameters:
versionLabel If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withVersionLabel(String versionLabel) {
        this. = versionLabel;
        return this;
    }

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.

Constraints:
Length: 1 - 100

Returns:
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.
    public String getTemplateName() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.

Constraints:
Length: 1 - 100

Parameters:
templateName If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.
    public void setTemplateName(String templateName) {
        this. = templateName;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.

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

Constraints:
Length: 1 - 100

Parameters:
templateName If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withTemplateName(String templateName) {
        this. = templateName;
        return this;
    }

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

Returns:
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.
    public String getEnvironmentId() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

Parameters:
environmentId If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.
    public void setEnvironmentId(String environmentId) {
        this. = environmentId;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

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

Parameters:
environmentId If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withEnvironmentId(String environmentId) {
        this. = environmentId;
        return this;
    }

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

Constraints:
Length: 4 - 23

Returns:
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.
    public String getEnvironmentName() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

Constraints:
Length: 4 - 23

Parameters:
environmentName If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.
    public void setEnvironmentName(String environmentName) {
        this. = environmentName;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

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

Constraints:
Length: 4 - 23

Parameters:
environmentName If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withEnvironmentName(String environmentName) {
        this. = environmentName;
        return this;
    }

    
If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.

Returns:
If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.
    public String getRequestId() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.

Parameters:
requestId If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.
    public void setRequestId(String requestId) {
        this. = requestId;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.

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

Parameters:
requestId If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withRequestId(String requestId) {
        this. = requestId;
        return this;
    }

    
If specified, limits the events returned from this call to include only those with the specified severity or higher.

Constraints:
Allowed Values: TRACE, DEBUG, INFO, WARN, ERROR, FATAL

Returns:
If specified, limits the events returned from this call to include only those with the specified severity or higher.
See also:
EventSeverity
    public String getSeverity() {
        return ;
    }
    
    
If specified, limits the events returned from this call to include only those with the specified severity or higher.

Constraints:
Allowed Values: TRACE, DEBUG, INFO, WARN, ERROR, FATAL

Parameters:
severity If specified, limits the events returned from this call to include only those with the specified severity or higher.
See also:
EventSeverity
    public void setSeverity(String severity) {
        this. = severity;
    }
    
    
If specified, limits the events returned from this call to include only those with the specified severity or higher.

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

Constraints:
Allowed Values: TRACE, DEBUG, INFO, WARN, ERROR, FATAL

Parameters:
severity If specified, limits the events returned from this call to include only those with the specified severity or higher.
Returns:
A reference to this updated object so that method calls can be chained together.
See also:
EventSeverity
    public DescribeEventsRequest withSeverity(String severity) {
        this. = severity;
        return this;
    }

    
If specified, limits the events returned from this call to include only those with the specified severity or higher.

Constraints:
Allowed Values: TRACE, DEBUG, INFO, WARN, ERROR, FATAL

Parameters:
severity If specified, limits the events returned from this call to include only those with the specified severity or higher.
See also:
EventSeverity
    public void setSeverity(EventSeverity severity) {
        this. = severity.toString();
    }
    
    
If specified, limits the events returned from this call to include only those with the specified severity or higher.

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

Constraints:
Allowed Values: TRACE, DEBUG, INFO, WARN, ERROR, FATAL

Parameters:
severity If specified, limits the events returned from this call to include only those with the specified severity or higher.
Returns:
A reference to this updated object so that method calls can be chained together.
See also:
EventSeverity
    public DescribeEventsRequest withSeverity(EventSeverity severity) {
        this. = severity.toString();
        return this;
    }

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.

Returns:
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.
    public java.util.Date getStartTime() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.

Parameters:
startTime If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.
    public void setStartTime(java.util.Date startTime) {
        this. = startTime;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.

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

Parameters:
startTime If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withStartTime(java.util.Date startTime) {
        this. = startTime;
        return this;
    }

    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.

Returns:
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.
    public java.util.Date getEndTime() {
        return ;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.

Parameters:
endTime If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.
    public void setEndTime(java.util.Date endTime) {
        this. = endTime;
    }
    
    
If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.

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

Parameters:
endTime If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withEndTime(java.util.Date endTime) {
        this. = endTime;
        return this;
    }

    
Specifies the maximum number of events that can be returned, beginning with the most recent event.

Constraints:
Range: 1 - 1000

Returns:
Specifies the maximum number of events that can be returned, beginning with the most recent event.
    public Integer getMaxRecords() {
        return ;
    }
    
    
Specifies the maximum number of events that can be returned, beginning with the most recent event.

Constraints:
Range: 1 - 1000

Parameters:
maxRecords Specifies the maximum number of events that can be returned, beginning with the most recent event.
    public void setMaxRecords(Integer maxRecords) {
        this. = maxRecords;
    }
    
    
Specifies the maximum number of events that can be returned, beginning with the most recent event.

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

Constraints:
Range: 1 - 1000

Parameters:
maxRecords Specifies the maximum number of events that can be returned, beginning with the most recent event.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withMaxRecords(Integer maxRecords) {
        this. = maxRecords;
        return this;
    }

    
Pagination token. If specified, the events return the next batch of results.

Returns:
Pagination token. If specified, the events return the next batch of results.
    public String getNextToken() {
        return ;
    }
    
    
Pagination token. If specified, the events return the next batch of results.

Parameters:
nextToken Pagination token. If specified, the events return the next batch of results.
    public void setNextToken(String nextToken) {
        this. = nextToken;
    }
    
    
Pagination token. If specified, the events return the next batch of results.

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

Parameters:
nextToken Pagination token. If specified, the events return the next batch of results.
Returns:
A reference to this updated object so that method calls can be chained together.
    public DescribeEventsRequest withNextToken(String nextToken) {
        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 (getApplicationName() != nullsb.append("ApplicationName: " + getApplicationName() + ",");
        if (getVersionLabel() != nullsb.append("VersionLabel: " + getVersionLabel() + ",");
        if (getTemplateName() != nullsb.append("TemplateName: " + getTemplateName() + ",");
        if (getEnvironmentId() != nullsb.append("EnvironmentId: " + getEnvironmentId() + ",");
        if (getEnvironmentName() != nullsb.append("EnvironmentName: " + getEnvironmentName() + ",");
        if (getRequestId() != nullsb.append("RequestId: " + getRequestId() + ",");
        if (getSeverity() != nullsb.append("Severity: " + getSeverity() + ",");
        if (getStartTime() != nullsb.append("StartTime: " + getStartTime() + ",");
        if (getEndTime() != nullsb.append("EndTime: " + getEndTime() + ",");
        if (getMaxRecords() != nullsb.append("MaxRecords: " + getMaxRecords() + ",");
        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 + ((getApplicationName() == null) ? 0 : getApplicationName().hashCode()); 
        hashCode = prime * hashCode + ((getVersionLabel() == null) ? 0 : getVersionLabel().hashCode()); 
        hashCode = prime * hashCode + ((getTemplateName() == null) ? 0 : getTemplateName().hashCode()); 
        hashCode = prime * hashCode + ((getEnvironmentId() == null) ? 0 : getEnvironmentId().hashCode()); 
        hashCode = prime * hashCode + ((getEnvironmentName() == null) ? 0 : getEnvironmentName().hashCode()); 
        hashCode = prime * hashCode + ((getRequestId() == null) ? 0 : getRequestId().hashCode()); 
        hashCode = prime * hashCode + ((getSeverity() == null) ? 0 : getSeverity().hashCode()); 
        hashCode = prime * hashCode + ((getStartTime() == null) ? 0 : getStartTime().hashCode()); 
        hashCode = prime * hashCode + ((getEndTime() == null) ? 0 : getEndTime().hashCode()); 
        hashCode = prime * hashCode + ((getMaxRecords() == null) ? 0 : getMaxRecords().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 DescribeEventsRequest == falsereturn false;
        DescribeEventsRequest other = (DescribeEventsRequest)obj;
        
        if (other.getApplicationName() == null ^ this.getApplicationName() == nullreturn false;
        if (other.getApplicationName() != null && other.getApplicationName().equals(this.getApplicationName()) == falsereturn false
        if (other.getVersionLabel() == null ^ this.getVersionLabel() == nullreturn false;
        if (other.getVersionLabel() != null && other.getVersionLabel().equals(this.getVersionLabel()) == falsereturn false
        if (other.getTemplateName() == null ^ this.getTemplateName() == nullreturn false;
        if (other.getTemplateName() != null && other.getTemplateName().equals(this.getTemplateName()) == falsereturn false
        if (other.getEnvironmentId() == null ^ this.getEnvironmentId() == nullreturn false;
        if (other.getEnvironmentId() != null && other.getEnvironmentId().equals(this.getEnvironmentId()) == falsereturn false
        if (other.getEnvironmentName() == null ^ this.getEnvironmentName() == nullreturn false;
        if (other.getEnvironmentName() != null && other.getEnvironmentName().equals(this.getEnvironmentName()) == falsereturn false
        if (other.getRequestId() == null ^ this.getRequestId() == nullreturn false;
        if (other.getRequestId() != null && other.getRequestId().equals(this.getRequestId()) == falsereturn false
        if (other.getSeverity() == null ^ this.getSeverity() == nullreturn false;
        if (other.getSeverity() != null && other.getSeverity().equals(this.getSeverity()) == falsereturn false
        if (other.getStartTime() == null ^ this.getStartTime() == nullreturn false;
        if (other.getStartTime() != null && other.getStartTime().equals(this.getStartTime()) == falsereturn false
        if (other.getEndTime() == null ^ this.getEndTime() == nullreturn false;
        if (other.getEndTime() != null && other.getEndTime().equals(this.getEndTime()) == falsereturn false
        if (other.getMaxRecords() == null ^ this.getMaxRecords() == nullreturn false;
        if (other.getMaxRecords() != null && other.getMaxRecords().equals(this.getMaxRecords()) == falsereturn false
        if (other.getNextToken() == null ^ this.getNextToken() == nullreturn false;
        if (other.getNextToken() != null && other.getNextToken().equals(this.getNextToken()) == falsereturn false
        return true;
    }
    
    @Override
    public DescribeEventsRequest clone() {
        
            return (DescribeEventsRequestsuper.clone();
    }
}
    
New to GrepCode? Check out our FAQ X