com.amazonaws.services.iottwinmaker.model.UpdateSceneRequest Maven / Gradle / Ivy
Show all versions of aws-java-sdk-iottwinmaker 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.iottwinmaker.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 UpdateSceneRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable {
/**
*
* The ID of the workspace that contains the scene.
*
*/
private String workspaceId;
/**
*
* The ID of the scene.
*
*/
private String sceneId;
/**
*
* The relative path that specifies the location of the content definition file.
*
*/
private String contentLocation;
/**
*
* The description of this scene.
*
*/
private String description;
/**
*
* A list of capabilities that the scene uses to render.
*
*/
private java.util.List capabilities;
/**
*
* The scene metadata.
*
*/
private java.util.Map sceneMetadata;
/**
*
* The ID of the workspace that contains the scene.
*
*
* @param workspaceId
* The ID of the workspace that contains the scene.
*/
public void setWorkspaceId(String workspaceId) {
this.workspaceId = workspaceId;
}
/**
*
* The ID of the workspace that contains the scene.
*
*
* @return The ID of the workspace that contains the scene.
*/
public String getWorkspaceId() {
return this.workspaceId;
}
/**
*
* The ID of the workspace that contains the scene.
*
*
* @param workspaceId
* The ID of the workspace that contains the scene.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest withWorkspaceId(String workspaceId) {
setWorkspaceId(workspaceId);
return this;
}
/**
*
* The ID of the scene.
*
*
* @param sceneId
* The ID of the scene.
*/
public void setSceneId(String sceneId) {
this.sceneId = sceneId;
}
/**
*
* The ID of the scene.
*
*
* @return The ID of the scene.
*/
public String getSceneId() {
return this.sceneId;
}
/**
*
* The ID of the scene.
*
*
* @param sceneId
* The ID of the scene.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest withSceneId(String sceneId) {
setSceneId(sceneId);
return this;
}
/**
*
* The relative path that specifies the location of the content definition file.
*
*
* @param contentLocation
* The relative path that specifies the location of the content definition file.
*/
public void setContentLocation(String contentLocation) {
this.contentLocation = contentLocation;
}
/**
*
* The relative path that specifies the location of the content definition file.
*
*
* @return The relative path that specifies the location of the content definition file.
*/
public String getContentLocation() {
return this.contentLocation;
}
/**
*
* The relative path that specifies the location of the content definition file.
*
*
* @param contentLocation
* The relative path that specifies the location of the content definition file.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest withContentLocation(String contentLocation) {
setContentLocation(contentLocation);
return this;
}
/**
*
* The description of this scene.
*
*
* @param description
* The description of this scene.
*/
public void setDescription(String description) {
this.description = description;
}
/**
*
* The description of this scene.
*
*
* @return The description of this scene.
*/
public String getDescription() {
return this.description;
}
/**
*
* The description of this scene.
*
*
* @param description
* The description of this scene.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest withDescription(String description) {
setDescription(description);
return this;
}
/**
*
* A list of capabilities that the scene uses to render.
*
*
* @return A list of capabilities that the scene uses to render.
*/
public java.util.List getCapabilities() {
return capabilities;
}
/**
*
* A list of capabilities that the scene uses to render.
*
*
* @param capabilities
* A list of capabilities that the scene uses to render.
*/
public void setCapabilities(java.util.Collection capabilities) {
if (capabilities == null) {
this.capabilities = null;
return;
}
this.capabilities = new java.util.ArrayList(capabilities);
}
/**
*
* A list of capabilities that the scene uses to render.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setCapabilities(java.util.Collection)} or {@link #withCapabilities(java.util.Collection)} if you want to
* override the existing values.
*
*
* @param capabilities
* A list of capabilities that the scene uses to render.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest withCapabilities(String... capabilities) {
if (this.capabilities == null) {
setCapabilities(new java.util.ArrayList(capabilities.length));
}
for (String ele : capabilities) {
this.capabilities.add(ele);
}
return this;
}
/**
*
* A list of capabilities that the scene uses to render.
*
*
* @param capabilities
* A list of capabilities that the scene uses to render.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest withCapabilities(java.util.Collection capabilities) {
setCapabilities(capabilities);
return this;
}
/**
*
* The scene metadata.
*
*
* @return The scene metadata.
*/
public java.util.Map getSceneMetadata() {
return sceneMetadata;
}
/**
*
* The scene metadata.
*
*
* @param sceneMetadata
* The scene metadata.
*/
public void setSceneMetadata(java.util.Map sceneMetadata) {
this.sceneMetadata = sceneMetadata;
}
/**
*
* The scene metadata.
*
*
* @param sceneMetadata
* The scene metadata.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest withSceneMetadata(java.util.Map sceneMetadata) {
setSceneMetadata(sceneMetadata);
return this;
}
/**
* Add a single SceneMetadata entry
*
* @see UpdateSceneRequest#withSceneMetadata
* @returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest addSceneMetadataEntry(String key, String value) {
if (null == this.sceneMetadata) {
this.sceneMetadata = new java.util.HashMap();
}
if (this.sceneMetadata.containsKey(key))
throw new IllegalArgumentException("Duplicated keys (" + key.toString() + ") are provided.");
this.sceneMetadata.put(key, value);
return this;
}
/**
* Removes all the entries added into SceneMetadata.
*
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSceneRequest clearSceneMetadataEntries() {
this.sceneMetadata = 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 (getWorkspaceId() != null)
sb.append("WorkspaceId: ").append(getWorkspaceId()).append(",");
if (getSceneId() != null)
sb.append("SceneId: ").append(getSceneId()).append(",");
if (getContentLocation() != null)
sb.append("ContentLocation: ").append(getContentLocation()).append(",");
if (getDescription() != null)
sb.append("Description: ").append(getDescription()).append(",");
if (getCapabilities() != null)
sb.append("Capabilities: ").append(getCapabilities()).append(",");
if (getSceneMetadata() != null)
sb.append("SceneMetadata: ").append(getSceneMetadata());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof UpdateSceneRequest == false)
return false;
UpdateSceneRequest other = (UpdateSceneRequest) obj;
if (other.getWorkspaceId() == null ^ this.getWorkspaceId() == null)
return false;
if (other.getWorkspaceId() != null && other.getWorkspaceId().equals(this.getWorkspaceId()) == false)
return false;
if (other.getSceneId() == null ^ this.getSceneId() == null)
return false;
if (other.getSceneId() != null && other.getSceneId().equals(this.getSceneId()) == false)
return false;
if (other.getContentLocation() == null ^ this.getContentLocation() == null)
return false;
if (other.getContentLocation() != null && other.getContentLocation().equals(this.getContentLocation()) == 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.getCapabilities() == null ^ this.getCapabilities() == null)
return false;
if (other.getCapabilities() != null && other.getCapabilities().equals(this.getCapabilities()) == false)
return false;
if (other.getSceneMetadata() == null ^ this.getSceneMetadata() == null)
return false;
if (other.getSceneMetadata() != null && other.getSceneMetadata().equals(this.getSceneMetadata()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getWorkspaceId() == null) ? 0 : getWorkspaceId().hashCode());
hashCode = prime * hashCode + ((getSceneId() == null) ? 0 : getSceneId().hashCode());
hashCode = prime * hashCode + ((getContentLocation() == null) ? 0 : getContentLocation().hashCode());
hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode());
hashCode = prime * hashCode + ((getCapabilities() == null) ? 0 : getCapabilities().hashCode());
hashCode = prime * hashCode + ((getSceneMetadata() == null) ? 0 : getSceneMetadata().hashCode());
return hashCode;
}
@Override
public UpdateSceneRequest clone() {
return (UpdateSceneRequest) super.clone();
}
}