com.amazonaws.services.cleanrooms.model.PrivacyBudgetSummary Maven / Gradle / Ivy
Show all versions of aws-java-sdk-cleanrooms Show documentation
/*
* 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.cleanrooms.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* An array that summaries the specified privacy budget. This summary includes collaboration information, creation
* information, membership information, and privacy budget information.
*
*
* @see AWS
* API Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class PrivacyBudgetSummary implements Serializable, Cloneable, StructuredPojo {
/**
*
* The unique identifier of the privacy budget.
*
*/
private String id;
/**
*
* The unique identifier of the privacy budget template.
*
*/
private String privacyBudgetTemplateId;
/**
*
* The ARN of the privacy budget template.
*
*/
private String privacyBudgetTemplateArn;
/**
*
* The identifier for a membership resource.
*
*/
private String membershipId;
/**
*
* The Amazon Resource Name (ARN) of the member who created the privacy budget summary.
*
*/
private String membershipArn;
/**
*
* The unique identifier of the collaboration that contains this privacy budget.
*
*/
private String collaborationId;
/**
*
* The ARN of the collaboration that contains this privacy budget.
*
*/
private String collaborationArn;
/**
*
* Specifies the type of the privacy budget.
*
*/
private String type;
/**
*
* The time at which the privacy budget was created.
*
*/
private java.util.Date createTime;
/**
*
* The most recent time at which the privacy budget was updated.
*
*/
private java.util.Date updateTime;
/**
*
* The provided privacy budget.
*
*/
private PrivacyBudget budget;
/**
*
* The unique identifier of the privacy budget.
*
*
* @param id
* The unique identifier of the privacy budget.
*/
public void setId(String id) {
this.id = id;
}
/**
*
* The unique identifier of the privacy budget.
*
*
* @return The unique identifier of the privacy budget.
*/
public String getId() {
return this.id;
}
/**
*
* The unique identifier of the privacy budget.
*
*
* @param id
* The unique identifier of the privacy budget.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withId(String id) {
setId(id);
return this;
}
/**
*
* The unique identifier of the privacy budget template.
*
*
* @param privacyBudgetTemplateId
* The unique identifier of the privacy budget template.
*/
public void setPrivacyBudgetTemplateId(String privacyBudgetTemplateId) {
this.privacyBudgetTemplateId = privacyBudgetTemplateId;
}
/**
*
* The unique identifier of the privacy budget template.
*
*
* @return The unique identifier of the privacy budget template.
*/
public String getPrivacyBudgetTemplateId() {
return this.privacyBudgetTemplateId;
}
/**
*
* The unique identifier of the privacy budget template.
*
*
* @param privacyBudgetTemplateId
* The unique identifier of the privacy budget template.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withPrivacyBudgetTemplateId(String privacyBudgetTemplateId) {
setPrivacyBudgetTemplateId(privacyBudgetTemplateId);
return this;
}
/**
*
* The ARN of the privacy budget template.
*
*
* @param privacyBudgetTemplateArn
* The ARN of the privacy budget template.
*/
public void setPrivacyBudgetTemplateArn(String privacyBudgetTemplateArn) {
this.privacyBudgetTemplateArn = privacyBudgetTemplateArn;
}
/**
*
* The ARN of the privacy budget template.
*
*
* @return The ARN of the privacy budget template.
*/
public String getPrivacyBudgetTemplateArn() {
return this.privacyBudgetTemplateArn;
}
/**
*
* The ARN of the privacy budget template.
*
*
* @param privacyBudgetTemplateArn
* The ARN of the privacy budget template.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withPrivacyBudgetTemplateArn(String privacyBudgetTemplateArn) {
setPrivacyBudgetTemplateArn(privacyBudgetTemplateArn);
return this;
}
/**
*
* The identifier for a membership resource.
*
*
* @param membershipId
* The identifier for a membership resource.
*/
public void setMembershipId(String membershipId) {
this.membershipId = membershipId;
}
/**
*
* The identifier for a membership resource.
*
*
* @return The identifier for a membership resource.
*/
public String getMembershipId() {
return this.membershipId;
}
/**
*
* The identifier for a membership resource.
*
*
* @param membershipId
* The identifier for a membership resource.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withMembershipId(String membershipId) {
setMembershipId(membershipId);
return this;
}
/**
*
* The Amazon Resource Name (ARN) of the member who created the privacy budget summary.
*
*
* @param membershipArn
* The Amazon Resource Name (ARN) of the member who created the privacy budget summary.
*/
public void setMembershipArn(String membershipArn) {
this.membershipArn = membershipArn;
}
/**
*
* The Amazon Resource Name (ARN) of the member who created the privacy budget summary.
*
*
* @return The Amazon Resource Name (ARN) of the member who created the privacy budget summary.
*/
public String getMembershipArn() {
return this.membershipArn;
}
/**
*
* The Amazon Resource Name (ARN) of the member who created the privacy budget summary.
*
*
* @param membershipArn
* The Amazon Resource Name (ARN) of the member who created the privacy budget summary.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withMembershipArn(String membershipArn) {
setMembershipArn(membershipArn);
return this;
}
/**
*
* The unique identifier of the collaboration that contains this privacy budget.
*
*
* @param collaborationId
* The unique identifier of the collaboration that contains this privacy budget.
*/
public void setCollaborationId(String collaborationId) {
this.collaborationId = collaborationId;
}
/**
*
* The unique identifier of the collaboration that contains this privacy budget.
*
*
* @return The unique identifier of the collaboration that contains this privacy budget.
*/
public String getCollaborationId() {
return this.collaborationId;
}
/**
*
* The unique identifier of the collaboration that contains this privacy budget.
*
*
* @param collaborationId
* The unique identifier of the collaboration that contains this privacy budget.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withCollaborationId(String collaborationId) {
setCollaborationId(collaborationId);
return this;
}
/**
*
* The ARN of the collaboration that contains this privacy budget.
*
*
* @param collaborationArn
* The ARN of the collaboration that contains this privacy budget.
*/
public void setCollaborationArn(String collaborationArn) {
this.collaborationArn = collaborationArn;
}
/**
*
* The ARN of the collaboration that contains this privacy budget.
*
*
* @return The ARN of the collaboration that contains this privacy budget.
*/
public String getCollaborationArn() {
return this.collaborationArn;
}
/**
*
* The ARN of the collaboration that contains this privacy budget.
*
*
* @param collaborationArn
* The ARN of the collaboration that contains this privacy budget.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withCollaborationArn(String collaborationArn) {
setCollaborationArn(collaborationArn);
return this;
}
/**
*
* Specifies the type of the privacy budget.
*
*
* @param type
* Specifies the type of the privacy budget.
* @see PrivacyBudgetType
*/
public void setType(String type) {
this.type = type;
}
/**
*
* Specifies the type of the privacy budget.
*
*
* @return Specifies the type of the privacy budget.
* @see PrivacyBudgetType
*/
public String getType() {
return this.type;
}
/**
*
* Specifies the type of the privacy budget.
*
*
* @param type
* Specifies the type of the privacy budget.
* @return Returns a reference to this object so that method calls can be chained together.
* @see PrivacyBudgetType
*/
public PrivacyBudgetSummary withType(String type) {
setType(type);
return this;
}
/**
*
* Specifies the type of the privacy budget.
*
*
* @param type
* Specifies the type of the privacy budget.
* @return Returns a reference to this object so that method calls can be chained together.
* @see PrivacyBudgetType
*/
public PrivacyBudgetSummary withType(PrivacyBudgetType type) {
this.type = type.toString();
return this;
}
/**
*
* The time at which the privacy budget was created.
*
*
* @param createTime
* The time at which the privacy budget was created.
*/
public void setCreateTime(java.util.Date createTime) {
this.createTime = createTime;
}
/**
*
* The time at which the privacy budget was created.
*
*
* @return The time at which the privacy budget was created.
*/
public java.util.Date getCreateTime() {
return this.createTime;
}
/**
*
* The time at which the privacy budget was created.
*
*
* @param createTime
* The time at which the privacy budget was created.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withCreateTime(java.util.Date createTime) {
setCreateTime(createTime);
return this;
}
/**
*
* The most recent time at which the privacy budget was updated.
*
*
* @param updateTime
* The most recent time at which the privacy budget was updated.
*/
public void setUpdateTime(java.util.Date updateTime) {
this.updateTime = updateTime;
}
/**
*
* The most recent time at which the privacy budget was updated.
*
*
* @return The most recent time at which the privacy budget was updated.
*/
public java.util.Date getUpdateTime() {
return this.updateTime;
}
/**
*
* The most recent time at which the privacy budget was updated.
*
*
* @param updateTime
* The most recent time at which the privacy budget was updated.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withUpdateTime(java.util.Date updateTime) {
setUpdateTime(updateTime);
return this;
}
/**
*
* The provided privacy budget.
*
*
* @param budget
* The provided privacy budget.
*/
public void setBudget(PrivacyBudget budget) {
this.budget = budget;
}
/**
*
* The provided privacy budget.
*
*
* @return The provided privacy budget.
*/
public PrivacyBudget getBudget() {
return this.budget;
}
/**
*
* The provided privacy budget.
*
*
* @param budget
* The provided privacy budget.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PrivacyBudgetSummary withBudget(PrivacyBudget budget) {
setBudget(budget);
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 (getId() != null)
sb.append("Id: ").append(getId()).append(",");
if (getPrivacyBudgetTemplateId() != null)
sb.append("PrivacyBudgetTemplateId: ").append(getPrivacyBudgetTemplateId()).append(",");
if (getPrivacyBudgetTemplateArn() != null)
sb.append("PrivacyBudgetTemplateArn: ").append(getPrivacyBudgetTemplateArn()).append(",");
if (getMembershipId() != null)
sb.append("MembershipId: ").append(getMembershipId()).append(",");
if (getMembershipArn() != null)
sb.append("MembershipArn: ").append(getMembershipArn()).append(",");
if (getCollaborationId() != null)
sb.append("CollaborationId: ").append(getCollaborationId()).append(",");
if (getCollaborationArn() != null)
sb.append("CollaborationArn: ").append(getCollaborationArn()).append(",");
if (getType() != null)
sb.append("Type: ").append(getType()).append(",");
if (getCreateTime() != null)
sb.append("CreateTime: ").append(getCreateTime()).append(",");
if (getUpdateTime() != null)
sb.append("UpdateTime: ").append(getUpdateTime()).append(",");
if (getBudget() != null)
sb.append("Budget: ").append(getBudget());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof PrivacyBudgetSummary == false)
return false;
PrivacyBudgetSummary other = (PrivacyBudgetSummary) obj;
if (other.getId() == null ^ this.getId() == null)
return false;
if (other.getId() != null && other.getId().equals(this.getId()) == false)
return false;
if (other.getPrivacyBudgetTemplateId() == null ^ this.getPrivacyBudgetTemplateId() == null)
return false;
if (other.getPrivacyBudgetTemplateId() != null && other.getPrivacyBudgetTemplateId().equals(this.getPrivacyBudgetTemplateId()) == false)
return false;
if (other.getPrivacyBudgetTemplateArn() == null ^ this.getPrivacyBudgetTemplateArn() == null)
return false;
if (other.getPrivacyBudgetTemplateArn() != null && other.getPrivacyBudgetTemplateArn().equals(this.getPrivacyBudgetTemplateArn()) == false)
return false;
if (other.getMembershipId() == null ^ this.getMembershipId() == null)
return false;
if (other.getMembershipId() != null && other.getMembershipId().equals(this.getMembershipId()) == false)
return false;
if (other.getMembershipArn() == null ^ this.getMembershipArn() == null)
return false;
if (other.getMembershipArn() != null && other.getMembershipArn().equals(this.getMembershipArn()) == false)
return false;
if (other.getCollaborationId() == null ^ this.getCollaborationId() == null)
return false;
if (other.getCollaborationId() != null && other.getCollaborationId().equals(this.getCollaborationId()) == false)
return false;
if (other.getCollaborationArn() == null ^ this.getCollaborationArn() == null)
return false;
if (other.getCollaborationArn() != null && other.getCollaborationArn().equals(this.getCollaborationArn()) == false)
return false;
if (other.getType() == null ^ this.getType() == null)
return false;
if (other.getType() != null && other.getType().equals(this.getType()) == false)
return false;
if (other.getCreateTime() == null ^ this.getCreateTime() == null)
return false;
if (other.getCreateTime() != null && other.getCreateTime().equals(this.getCreateTime()) == false)
return false;
if (other.getUpdateTime() == null ^ this.getUpdateTime() == null)
return false;
if (other.getUpdateTime() != null && other.getUpdateTime().equals(this.getUpdateTime()) == false)
return false;
if (other.getBudget() == null ^ this.getBudget() == null)
return false;
if (other.getBudget() != null && other.getBudget().equals(this.getBudget()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getId() == null) ? 0 : getId().hashCode());
hashCode = prime * hashCode + ((getPrivacyBudgetTemplateId() == null) ? 0 : getPrivacyBudgetTemplateId().hashCode());
hashCode = prime * hashCode + ((getPrivacyBudgetTemplateArn() == null) ? 0 : getPrivacyBudgetTemplateArn().hashCode());
hashCode = prime * hashCode + ((getMembershipId() == null) ? 0 : getMembershipId().hashCode());
hashCode = prime * hashCode + ((getMembershipArn() == null) ? 0 : getMembershipArn().hashCode());
hashCode = prime * hashCode + ((getCollaborationId() == null) ? 0 : getCollaborationId().hashCode());
hashCode = prime * hashCode + ((getCollaborationArn() == null) ? 0 : getCollaborationArn().hashCode());
hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode());
hashCode = prime * hashCode + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
hashCode = prime * hashCode + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
hashCode = prime * hashCode + ((getBudget() == null) ? 0 : getBudget().hashCode());
return hashCode;
}
@Override
public PrivacyBudgetSummary clone() {
try {
return (PrivacyBudgetSummary) 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.cleanrooms.model.transform.PrivacyBudgetSummaryMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}