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

com.amazonaws.services.mobile.model.CreateProjectRequest Maven / Gradle / Ivy

Go to download

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

There is a newer version: 1.12.764
Show newest version
/*
 * Copyright 2013-2018 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.mobile.model;

import java.io.Serializable;
import javax.annotation.Generated;

import com.amazonaws.AmazonWebServiceRequest;

/**
 * 

* Request structure used to request a project be created. *

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

* Name of the project. *

*/ private String name; /** *

* Default region where project resources should be created. *

*/ private String region; /** *

* ZIP or YAML file which contains configuration settings to be used when creating the project. This may be the * contents of the file downloaded from the URL provided in an export project operation. *

*/ private java.nio.ByteBuffer contents; /** *

* Unique identifier for an exported snapshot of project configuration. This snapshot identifier is included in the * share URL when a project is exported. *

*/ private String snapshotId; /** *

* Name of the project. *

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

* Name of the project. *

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

* Name of the project. *

* * @param name * Name of 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; } /** *

* Default region where project resources should be created. *

* * @param region * Default region where project resources should be created. */ public void setRegion(String region) { this.region = region; } /** *

* Default region where project resources should be created. *

* * @return Default region where project resources should be created. */ public String getRegion() { return this.region; } /** *

* Default region where project resources should be created. *

* * @param region * Default region where project resources should be created. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withRegion(String region) { setRegion(region); return this; } /** *

* ZIP or YAML file which contains configuration settings to be used when creating the project. This may be the * contents of the file downloaded from the URL provided in an export project operation. *

*

* The AWS SDK for Java performs a Base64 encoding on this field before sending this request to the AWS service. * Users of the SDK should not perform Base64 encoding on this field. *

*

* Warning: ByteBuffers returned by the SDK are mutable. Changes to the content or position of the byte buffer will * be seen by all objects that have a reference to this object. It is recommended to call ByteBuffer.duplicate() or * ByteBuffer.asReadOnlyBuffer() before using or reading from the buffer. This behavior will be changed in a future * major version of the SDK. *

* * @param contents * ZIP or YAML file which contains configuration settings to be used when creating the project. This may be * the contents of the file downloaded from the URL provided in an export project operation. */ public void setContents(java.nio.ByteBuffer contents) { this.contents = contents; } /** *

* ZIP or YAML file which contains configuration settings to be used when creating the project. This may be the * contents of the file downloaded from the URL provided in an export project operation. *

*

* {@code ByteBuffer}s are stateful. Calling their {@code get} methods changes their {@code position}. We recommend * using {@link java.nio.ByteBuffer#asReadOnlyBuffer()} to create a read-only view of the buffer with an independent * {@code position}, and calling {@code get} methods on this rather than directly on the returned {@code ByteBuffer}. * Doing so will ensure that anyone else using the {@code ByteBuffer} will not be affected by changes to the * {@code position}. *

* * @return ZIP or YAML file which contains configuration settings to be used when creating the project. This may be * the contents of the file downloaded from the URL provided in an export project operation. */ public java.nio.ByteBuffer getContents() { return this.contents; } /** *

* ZIP or YAML file which contains configuration settings to be used when creating the project. This may be the * contents of the file downloaded from the URL provided in an export project operation. *

*

* The AWS SDK for Java performs a Base64 encoding on this field before sending this request to the AWS service. * Users of the SDK should not perform Base64 encoding on this field. *

*

* Warning: ByteBuffers returned by the SDK are mutable. Changes to the content or position of the byte buffer will * be seen by all objects that have a reference to this object. It is recommended to call ByteBuffer.duplicate() or * ByteBuffer.asReadOnlyBuffer() before using or reading from the buffer. This behavior will be changed in a future * major version of the SDK. *

* * @param contents * ZIP or YAML file which contains configuration settings to be used when creating the project. This may be * the contents of the file downloaded from the URL provided in an export project operation. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withContents(java.nio.ByteBuffer contents) { setContents(contents); return this; } /** *

* Unique identifier for an exported snapshot of project configuration. This snapshot identifier is included in the * share URL when a project is exported. *

* * @param snapshotId * Unique identifier for an exported snapshot of project configuration. This snapshot identifier is included * in the share URL when a project is exported. */ public void setSnapshotId(String snapshotId) { this.snapshotId = snapshotId; } /** *

* Unique identifier for an exported snapshot of project configuration. This snapshot identifier is included in the * share URL when a project is exported. *

* * @return Unique identifier for an exported snapshot of project configuration. This snapshot identifier is included * in the share URL when a project is exported. */ public String getSnapshotId() { return this.snapshotId; } /** *

* Unique identifier for an exported snapshot of project configuration. This snapshot identifier is included in the * share URL when a project is exported. *

* * @param snapshotId * Unique identifier for an exported snapshot of project configuration. This snapshot identifier is included * in the share URL when a project is exported. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProjectRequest withSnapshotId(String snapshotId) { setSnapshotId(snapshotId); return this; } /** * Returns a string representation of this object; useful for testing and debugging. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getName() != null) sb.append("Name: ").append(getName()).append(","); if (getRegion() != null) sb.append("Region: ").append(getRegion()).append(","); if (getContents() != null) sb.append("Contents: ").append(getContents()).append(","); if (getSnapshotId() != null) sb.append("SnapshotId: ").append(getSnapshotId()); 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.getName() == null ^ this.getName() == null) return false; if (other.getName() != null && other.getName().equals(this.getName()) == false) return false; if (other.getRegion() == null ^ this.getRegion() == null) return false; if (other.getRegion() != null && other.getRegion().equals(this.getRegion()) == false) return false; if (other.getContents() == null ^ this.getContents() == null) return false; if (other.getContents() != null && other.getContents().equals(this.getContents()) == false) return false; if (other.getSnapshotId() == null ^ this.getSnapshotId() == null) return false; if (other.getSnapshotId() != null && other.getSnapshotId().equals(this.getSnapshotId()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getRegion() == null) ? 0 : getRegion().hashCode()); hashCode = prime * hashCode + ((getContents() == null) ? 0 : getContents().hashCode()); hashCode = prime * hashCode + ((getSnapshotId() == null) ? 0 : getSnapshotId().hashCode()); return hashCode; } @Override public CreateProjectRequest clone() { return (CreateProjectRequest) super.clone(); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy