All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.ssmincidents.model.EventSummary Maven / Gradle / Ivy

Go to download

The AWS Java SDK for AWS Systems Manager Incident Manager module holds the client classes that are used for communicating with AWS Systems Manager Incident Manager Service

There is a newer version: 1.12.778
Show newest version
/*
 * Copyright 2019-2024 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.ssmincidents.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Details about a timeline event during an incident. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class EventSummary implements Serializable, Cloneable, StructuredPojo { /** *

* The timeline event ID. *

*/ private String eventId; /** *

* A list of references in a TimelineEvent. *

*/ private java.util.List eventReferences; /** *

* The timestamp for when the event occurred. *

*/ private java.util.Date eventTime; /** *

* The type of event. The timeline event must be Custom Event or Note. *

*/ private String eventType; /** *

* The timestamp for when the timeline event was last updated. *

*/ private java.util.Date eventUpdatedTime; /** *

* The Amazon Resource Name (ARN) of the incident that the event happened during. *

*/ private String incidentRecordArn; /** *

* The timeline event ID. *

* * @param eventId * The timeline event ID. */ public void setEventId(String eventId) { this.eventId = eventId; } /** *

* The timeline event ID. *

* * @return The timeline event ID. */ public String getEventId() { return this.eventId; } /** *

* The timeline event ID. *

* * @param eventId * The timeline event ID. * @return Returns a reference to this object so that method calls can be chained together. */ public EventSummary withEventId(String eventId) { setEventId(eventId); return this; } /** *

* A list of references in a TimelineEvent. *

* * @return A list of references in a TimelineEvent. */ public java.util.List getEventReferences() { return eventReferences; } /** *

* A list of references in a TimelineEvent. *

* * @param eventReferences * A list of references in a TimelineEvent. */ public void setEventReferences(java.util.Collection eventReferences) { if (eventReferences == null) { this.eventReferences = null; return; } this.eventReferences = new java.util.ArrayList(eventReferences); } /** *

* A list of references in a TimelineEvent. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setEventReferences(java.util.Collection)} or {@link #withEventReferences(java.util.Collection)} if you * want to override the existing values. *

* * @param eventReferences * A list of references in a TimelineEvent. * @return Returns a reference to this object so that method calls can be chained together. */ public EventSummary withEventReferences(EventReference... eventReferences) { if (this.eventReferences == null) { setEventReferences(new java.util.ArrayList(eventReferences.length)); } for (EventReference ele : eventReferences) { this.eventReferences.add(ele); } return this; } /** *

* A list of references in a TimelineEvent. *

* * @param eventReferences * A list of references in a TimelineEvent. * @return Returns a reference to this object so that method calls can be chained together. */ public EventSummary withEventReferences(java.util.Collection eventReferences) { setEventReferences(eventReferences); return this; } /** *

* The timestamp for when the event occurred. *

* * @param eventTime * The timestamp for when the event occurred. */ public void setEventTime(java.util.Date eventTime) { this.eventTime = eventTime; } /** *

* The timestamp for when the event occurred. *

* * @return The timestamp for when the event occurred. */ public java.util.Date getEventTime() { return this.eventTime; } /** *

* The timestamp for when the event occurred. *

* * @param eventTime * The timestamp for when the event occurred. * @return Returns a reference to this object so that method calls can be chained together. */ public EventSummary withEventTime(java.util.Date eventTime) { setEventTime(eventTime); return this; } /** *

* The type of event. The timeline event must be Custom Event or Note. *

* * @param eventType * The type of event. The timeline event must be Custom Event or Note. */ public void setEventType(String eventType) { this.eventType = eventType; } /** *

* The type of event. The timeline event must be Custom Event or Note. *

* * @return The type of event. The timeline event must be Custom Event or Note. */ public String getEventType() { return this.eventType; } /** *

* The type of event. The timeline event must be Custom Event or Note. *

* * @param eventType * The type of event. The timeline event must be Custom Event or Note. * @return Returns a reference to this object so that method calls can be chained together. */ public EventSummary withEventType(String eventType) { setEventType(eventType); return this; } /** *

* The timestamp for when the timeline event was last updated. *

* * @param eventUpdatedTime * The timestamp for when the timeline event was last updated. */ public void setEventUpdatedTime(java.util.Date eventUpdatedTime) { this.eventUpdatedTime = eventUpdatedTime; } /** *

* The timestamp for when the timeline event was last updated. *

* * @return The timestamp for when the timeline event was last updated. */ public java.util.Date getEventUpdatedTime() { return this.eventUpdatedTime; } /** *

* The timestamp for when the timeline event was last updated. *

* * @param eventUpdatedTime * The timestamp for when the timeline event was last updated. * @return Returns a reference to this object so that method calls can be chained together. */ public EventSummary withEventUpdatedTime(java.util.Date eventUpdatedTime) { setEventUpdatedTime(eventUpdatedTime); return this; } /** *

* The Amazon Resource Name (ARN) of the incident that the event happened during. *

* * @param incidentRecordArn * The Amazon Resource Name (ARN) of the incident that the event happened during. */ public void setIncidentRecordArn(String incidentRecordArn) { this.incidentRecordArn = incidentRecordArn; } /** *

* The Amazon Resource Name (ARN) of the incident that the event happened during. *

* * @return The Amazon Resource Name (ARN) of the incident that the event happened during. */ public String getIncidentRecordArn() { return this.incidentRecordArn; } /** *

* The Amazon Resource Name (ARN) of the incident that the event happened during. *

* * @param incidentRecordArn * The Amazon Resource Name (ARN) of the incident that the event happened during. * @return Returns a reference to this object so that method calls can be chained together. */ public EventSummary withIncidentRecordArn(String incidentRecordArn) { setIncidentRecordArn(incidentRecordArn); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getEventId() != null) sb.append("EventId: ").append(getEventId()).append(","); if (getEventReferences() != null) sb.append("EventReferences: ").append(getEventReferences()).append(","); if (getEventTime() != null) sb.append("EventTime: ").append(getEventTime()).append(","); if (getEventType() != null) sb.append("EventType: ").append(getEventType()).append(","); if (getEventUpdatedTime() != null) sb.append("EventUpdatedTime: ").append(getEventUpdatedTime()).append(","); if (getIncidentRecordArn() != null) sb.append("IncidentRecordArn: ").append(getIncidentRecordArn()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof EventSummary == false) return false; EventSummary other = (EventSummary) obj; if (other.getEventId() == null ^ this.getEventId() == null) return false; if (other.getEventId() != null && other.getEventId().equals(this.getEventId()) == false) return false; if (other.getEventReferences() == null ^ this.getEventReferences() == null) return false; if (other.getEventReferences() != null && other.getEventReferences().equals(this.getEventReferences()) == false) return false; if (other.getEventTime() == null ^ this.getEventTime() == null) return false; if (other.getEventTime() != null && other.getEventTime().equals(this.getEventTime()) == false) return false; if (other.getEventType() == null ^ this.getEventType() == null) return false; if (other.getEventType() != null && other.getEventType().equals(this.getEventType()) == false) return false; if (other.getEventUpdatedTime() == null ^ this.getEventUpdatedTime() == null) return false; if (other.getEventUpdatedTime() != null && other.getEventUpdatedTime().equals(this.getEventUpdatedTime()) == false) return false; if (other.getIncidentRecordArn() == null ^ this.getIncidentRecordArn() == null) return false; if (other.getIncidentRecordArn() != null && other.getIncidentRecordArn().equals(this.getIncidentRecordArn()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getEventId() == null) ? 0 : getEventId().hashCode()); hashCode = prime * hashCode + ((getEventReferences() == null) ? 0 : getEventReferences().hashCode()); hashCode = prime * hashCode + ((getEventTime() == null) ? 0 : getEventTime().hashCode()); hashCode = prime * hashCode + ((getEventType() == null) ? 0 : getEventType().hashCode()); hashCode = prime * hashCode + ((getEventUpdatedTime() == null) ? 0 : getEventUpdatedTime().hashCode()); hashCode = prime * hashCode + ((getIncidentRecordArn() == null) ? 0 : getIncidentRecordArn().hashCode()); return hashCode; } @Override public EventSummary clone() { try { return (EventSummary) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.ssmincidents.model.transform.EventSummaryMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy