/* * Copyright 2018-2023 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.cloudwatchevidently.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.AmazonWebServiceRequest; /** * * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class CreateProjectRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *

* Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side * evaluation allows your application to assign variations to user sessions locally instead of by calling the EvaluateFeature * operation. This mitigates the latency and availability risks that come with an API call. For more * information, see Client-side evaluation - powered by AppConfig. *

*

* This parameter is a structure that contains information about the AppConfig application and environment that will * be used as for client-side evaluation. *

*

* To create a project that uses client-side evaluation, you must have the * evidently:ExportProjectAsConfiguration permission. *

*/ private ProjectAppConfigResourceConfig appConfigResource; /** *

* A structure that contains information about where Evidently is to store evaluation events for longer term * storage, if you choose to do so. If you choose not to store these events, Evidently deletes them after using them * to produce metrics and other experiment results that you can view. *

*/ private ProjectDataDeliveryConfig dataDelivery; /** *

* An optional description of the project. *

*/ private String description; /** *

* The name for the project. *

*/ private String name; /** *

* Assigns one or more tags (key-value pairs) to the project. *

*

* Tags can help you organize and categorize your resources. You can also use them to scope user permissions by * granting a user permission to access or change only resources with certain tag values. *

*

* Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of * characters. *

*

* You can associate as many as 50 tags with a project. *

*

* For more information, see Tagging Amazon * Web Services resources. *

*/ private java.util.Map tags; /** *

* Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side * evaluation allows your application to assign variations to user sessions locally instead of by calling the EvaluateFeature * operation. This mitigates the latency and availability risks that come with an API call. For more * information, see Client-side evaluation - powered by AppConfig. *

*

* This parameter is a structure that contains information about the AppConfig application and environment that will * be used as for client-side evaluation. *

*

* To create a project that uses client-side evaluation, you must have the * evidently:ExportProjectAsConfiguration permission. *

* * @param appConfigResource * Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side * evaluation allows your application to assign variations to user sessions locally instead of by calling the * * EvaluateFeature operation. This mitigates the latency and availability risks that come with an API * call. For more information, see Client-side evaluation - powered by AppConfig.

*

* This parameter is a structure that contains information about the AppConfig application and environment * that will be used as for client-side evaluation. *

*

* To create a project that uses client-side evaluation, you must have the * evidently:ExportProjectAsConfiguration permission. */ public void setAppConfigResource(ProjectAppConfigResourceConfig appConfigResource) { this.appConfigResource = appConfigResource; } /** *

* Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side * evaluation allows your application to assign variations to user sessions locally instead of by calling the EvaluateFeature * operation. This mitigates the latency and availability risks that come with an API call. For more * information, see Client-side evaluation - powered by AppConfig. *

*

* This parameter is a structure that contains information about the AppConfig application and environment that will * be used as for client-side evaluation. *

*

* To create a project that uses client-side evaluation, you must have the * evidently:ExportProjectAsConfiguration permission. *

* * @return Use this parameter if the project will use client-side evaluation powered by AppConfig. * Client-side evaluation allows your application to assign variations to user sessions locally instead of * by calling the EvaluateFeature operation. This mitigates the latency and availability risks that come with an API * call. For more information, see Client-side evaluation - powered by AppConfig.

*

* This parameter is a structure that contains information about the AppConfig application and environment * that will be used as for client-side evaluation. *

*

* To create a project that uses client-side evaluation, you must have the * evidently:ExportProjectAsConfiguration permission. */ public ProjectAppConfigResourceConfig getAppConfigResource() { return this.appConfigResource; } /** *

* Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side * evaluation allows your application to assign variations to user sessions locally instead of by calling the EvaluateFeature * operation. This mitigates the latency and availability risks that come with an API call. For more * information, see Client-side evaluation - powered by AppConfig. *

*

* This parameter is a structure that contains information about the AppConfig application and environment that will * be used as for client-side evaluation. *

*

* To create a project that uses client-side evaluation, you must have the * evidently:ExportProjectAsConfiguration permission. *

* * @param appConfigResource * Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side * evaluation allows your application to assign variations to user sessions locally instead of by calling the * * EvaluateFeature operation. This mitigates the latency and availability risks that come with an API * call. For more information, see Client-side evaluation - powered by AppConfig.

*

* This parameter is a structure that contains information about the AppConfig application and environment * that will be used as for client-side evaluation. *

*

* To create a project that uses client-side evaluation, you must have the * evidently:ExportProjectAsConfiguration permission. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withAppConfigResource(ProjectAppConfigResourceConfig appConfigResource) { setAppConfigResource(appConfigResource); return this; } /** *

* A structure that contains information about where Evidently is to store evaluation events for longer term * storage, if you choose to do so. If you choose not to store these events, Evidently deletes them after using them * to produce metrics and other experiment results that you can view. *

* * @param dataDelivery * A structure that contains information about where Evidently is to store evaluation events for longer term * storage, if you choose to do so. If you choose not to store these events, Evidently deletes them after * using them to produce metrics and other experiment results that you can view. */ public void setDataDelivery(ProjectDataDeliveryConfig dataDelivery) { this.dataDelivery = dataDelivery; } /** *

* A structure that contains information about where Evidently is to store evaluation events for longer term * storage, if you choose to do so. If you choose not to store these events, Evidently deletes them after using them * to produce metrics and other experiment results that you can view. *

* * @return A structure that contains information about where Evidently is to store evaluation events for longer term * storage, if you choose to do so. If you choose not to store these events, Evidently deletes them after * using them to produce metrics and other experiment results that you can view. */ public ProjectDataDeliveryConfig getDataDelivery() { return this.dataDelivery; } /** *

* A structure that contains information about where Evidently is to store evaluation events for longer term * storage, if you choose to do so. If you choose not to store these events, Evidently deletes them after using them * to produce metrics and other experiment results that you can view. *

* * @param dataDelivery * A structure that contains information about where Evidently is to store evaluation events for longer term * storage, if you choose to do so. If you choose not to store these events, Evidently deletes them after * using them to produce metrics and other experiment results that you can view. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withDataDelivery(ProjectDataDeliveryConfig dataDelivery) { setDataDelivery(dataDelivery); return this; } /** *

* An optional description of the project. *

* * @param description * An optional description of the project. */ public void setDescription(String description) { this.description = description; } /** *

* An optional description of the project. *

* * @return An optional description of the project. */ public String getDescription() { return this.description; } /** *

* An optional description of the project. *

* * @param description * An optional description of the project. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withDescription(String description) { setDescription(description); return this; } /** *

* The name for the project. *

* * @param name * The name for the project. */ public void setName(String name) { this.name = name; } /** *

* The name for the project. *

* * @return The name for the project. */ public String getName() { return this.name; } /** *

* The name for the project. *

* * @param name * The name for the project. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withName(String name) { setName(name); return this; } /** *

* Assigns one or more tags (key-value pairs) to the project. *

*

* Tags can help you organize and categorize your resources. You can also use them to scope user permissions by * granting a user permission to access or change only resources with certain tag values. *

*

* Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of * characters. *

*

* You can associate as many as 50 tags with a project. *

*

* For more information, see Tagging Amazon * Web Services resources. *

* * @return Assigns one or more tags (key-value pairs) to the project.

*

* Tags can help you organize and categorize your resources. You can also use them to scope user permissions * by granting a user permission to access or change only resources with certain tag values. *

*

* Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of * characters. *

*

* You can associate as many as 50 tags with a project. *

*

* For more information, see Tagging Amazon Web Services * resources. */ public java.util.Map getTags() { return tags; } /** *

* Assigns one or more tags (key-value pairs) to the project. *

*

* Tags can help you organize and categorize your resources. You can also use them to scope user permissions by * granting a user permission to access or change only resources with certain tag values. *

*

* Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of * characters. *

*

* You can associate as many as 50 tags with a project. *

*

* For more information, see Tagging Amazon * Web Services resources. *

* * @param tags * Assigns one or more tags (key-value pairs) to the project.

*

* Tags can help you organize and categorize your resources. You can also use them to scope user permissions * by granting a user permission to access or change only resources with certain tag values. *

*

* Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of * characters. *

*

* You can associate as many as 50 tags with a project. *

*

* For more information, see Tagging * Amazon Web Services resources. */ public void setTags(java.util.Map tags) { this.tags = tags; } /** *

* Assigns one or more tags (key-value pairs) to the project. *

*

* Tags can help you organize and categorize your resources. You can also use them to scope user permissions by * granting a user permission to access or change only resources with certain tag values. *

*

* Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of * characters. *

*

* You can associate as many as 50 tags with a project. *

*

* For more information, see Tagging Amazon * Web Services resources. *

* * @param tags * Assigns one or more tags (key-value pairs) to the project.

*

* Tags can help you organize and categorize your resources. You can also use them to scope user permissions * by granting a user permission to access or change only resources with certain tag values. *

*

* Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of * characters. *

*

* You can associate as many as 50 tags with a project. *

*

* For more information, see Tagging * Amazon Web Services resources. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withTags(java.util.Map tags) { setTags(tags); return this; } /** * Add a single Tags entry * * @see CreateProjectRequest#withTags * @returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest addTagsEntry(String key, String value) { if (null == this.tags) { this.tags = new java.util.HashMap(); } if (this.tags.containsKey(key)) throw new IllegalArgumentException("Duplicated keys (" + key.toString() + ") are provided."); this.tags.put(key, value); return this; } /** * Removes all the entries added into Tags. * * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest clearTagsEntries() { this.tags = null; 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 (getAppConfigResource() != null) sb.append("AppConfigResource: ").append(getAppConfigResource()).append(","); if (getDataDelivery() != null) sb.append("DataDelivery: ").append(getDataDelivery()).append(","); if (getDescription() != null) sb.append("Description: ").append(getDescription()).append(","); if (getName() != null) sb.append("Name: ").append(getName()).append(","); if (getTags() != null) sb.append("Tags: ").append(getTags()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof CreateProjectRequest == false) return false; CreateProjectRequest other = (CreateProjectRequest) obj; if (other.getAppConfigResource() == null ^ this.getAppConfigResource() == null) return false; if (other.getAppConfigResource() != null && other.getAppConfigResource().equals(this.getAppConfigResource()) == false) return false; if (other.getDataDelivery() == null ^ this.getDataDelivery() == null) return false; if (other.getDataDelivery() != null && other.getDataDelivery().equals(this.getDataDelivery()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getName() == null ^ this.getName() == null) return false; if (other.getName() != null && other.getName().equals(this.getName()) == false) return false; if (other.getTags() == null ^ this.getTags() == null) return false; if (other.getTags() != null && other.getTags().equals(this.getTags()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAppConfigResource() == null) ? 0 : getAppConfigResource().hashCode()); hashCode = prime * hashCode + ((getDataDelivery() == null) ? 0 : getDataDelivery().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getTags() == null) ? 0 : getTags().hashCode()); return hashCode; } @Override public CreateProjectRequest clone() { return (CreateProjectRequest) super.clone(); } }