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

com.amazonaws.services.qapps.model.AppDefinition Maven / Gradle / Ivy

Go to download

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

There is a newer version: 1.12.772
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.qapps.model;

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

/**
 * 

* The definition of the Q App, specifying the cards and flow. *

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

* The version of the app definition schema or specification. *

*/ private String appDefinitionVersion; /** *

* The cards that make up the Q App, such as text input, file upload, or query cards. *

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

* A flag indicating whether the Q App's definition can be edited by the user. *

*/ private Boolean canEdit; /** *

* The version of the app definition schema or specification. *

* * @param appDefinitionVersion * The version of the app definition schema or specification. */ public void setAppDefinitionVersion(String appDefinitionVersion) { this.appDefinitionVersion = appDefinitionVersion; } /** *

* The version of the app definition schema or specification. *

* * @return The version of the app definition schema or specification. */ public String getAppDefinitionVersion() { return this.appDefinitionVersion; } /** *

* The version of the app definition schema or specification. *

* * @param appDefinitionVersion * The version of the app definition schema or specification. * @return Returns a reference to this object so that method calls can be chained together. */ public AppDefinition withAppDefinitionVersion(String appDefinitionVersion) { setAppDefinitionVersion(appDefinitionVersion); return this; } /** *

* The cards that make up the Q App, such as text input, file upload, or query cards. *

* * @return The cards that make up the Q App, such as text input, file upload, or query cards. */ public java.util.List getCards() { return cards; } /** *

* The cards that make up the Q App, such as text input, file upload, or query cards. *

* * @param cards * The cards that make up the Q App, such as text input, file upload, or query cards. */ public void setCards(java.util.Collection cards) { if (cards == null) { this.cards = null; return; } this.cards = new java.util.ArrayList(cards); } /** *

* The cards that make up the Q App, such as text input, file upload, or query cards. *

*

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

* * @param cards * The cards that make up the Q App, such as text input, file upload, or query cards. * @return Returns a reference to this object so that method calls can be chained together. */ public AppDefinition withCards(Card... cards) { if (this.cards == null) { setCards(new java.util.ArrayList(cards.length)); } for (Card ele : cards) { this.cards.add(ele); } return this; } /** *

* The cards that make up the Q App, such as text input, file upload, or query cards. *

* * @param cards * The cards that make up the Q App, such as text input, file upload, or query cards. * @return Returns a reference to this object so that method calls can be chained together. */ public AppDefinition withCards(java.util.Collection cards) { setCards(cards); return this; } /** *

* A flag indicating whether the Q App's definition can be edited by the user. *

* * @param canEdit * A flag indicating whether the Q App's definition can be edited by the user. */ public void setCanEdit(Boolean canEdit) { this.canEdit = canEdit; } /** *

* A flag indicating whether the Q App's definition can be edited by the user. *

* * @return A flag indicating whether the Q App's definition can be edited by the user. */ public Boolean getCanEdit() { return this.canEdit; } /** *

* A flag indicating whether the Q App's definition can be edited by the user. *

* * @param canEdit * A flag indicating whether the Q App's definition can be edited by the user. * @return Returns a reference to this object so that method calls can be chained together. */ public AppDefinition withCanEdit(Boolean canEdit) { setCanEdit(canEdit); return this; } /** *

* A flag indicating whether the Q App's definition can be edited by the user. *

* * @return A flag indicating whether the Q App's definition can be edited by the user. */ public Boolean isCanEdit() { return this.canEdit; } /** * 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 (getAppDefinitionVersion() != null) sb.append("AppDefinitionVersion: ").append(getAppDefinitionVersion()).append(","); if (getCards() != null) sb.append("Cards: ").append(getCards()).append(","); if (getCanEdit() != null) sb.append("CanEdit: ").append(getCanEdit()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof AppDefinition == false) return false; AppDefinition other = (AppDefinition) obj; if (other.getAppDefinitionVersion() == null ^ this.getAppDefinitionVersion() == null) return false; if (other.getAppDefinitionVersion() != null && other.getAppDefinitionVersion().equals(this.getAppDefinitionVersion()) == false) return false; if (other.getCards() == null ^ this.getCards() == null) return false; if (other.getCards() != null && other.getCards().equals(this.getCards()) == false) return false; if (other.getCanEdit() == null ^ this.getCanEdit() == null) return false; if (other.getCanEdit() != null && other.getCanEdit().equals(this.getCanEdit()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAppDefinitionVersion() == null) ? 0 : getAppDefinitionVersion().hashCode()); hashCode = prime * hashCode + ((getCards() == null) ? 0 : getCards().hashCode()); hashCode = prime * hashCode + ((getCanEdit() == null) ? 0 : getCanEdit().hashCode()); return hashCode; } @Override public AppDefinition clone() { try { return (AppDefinition) 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.qapps.model.transform.AppDefinitionMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy