/*
* Copyright 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.
*/
/*
* Do not modify this file. This file is generated from the mediastore-data-2017-09-01.normal.json service model.
*/
using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using System.Text;
using System.IO;
using System.Net;
using Amazon.Runtime;
using Amazon.Runtime.Internal;
using Amazon.Runtime.Internal.Auth;
namespace Amazon.MediaStoreData.Model
{
///
/// Container for the parameters to the PutObject operation.
/// Uploads an object to the specified path. Object sizes are limited to 25 MB for standard
/// upload availability and 10 MB for streaming upload availability.
///
public partial class PutObjectRequest : AmazonMediaStoreDataRequest
{
private Stream _body;
private string _cacheControl;
private string _contentType;
private string _path;
private StorageClass _storageClass;
private UploadAvailability _uploadAvailability;
///
/// Gets and sets the property Body.
///
/// The bytes to be stored.
///
///
[AWSProperty(Required=true)]
public Stream Body
{
get { return this._body; }
set { this._body = value; }
}
// Check to see if Body property is set
internal bool IsSetBody()
{
return this._body != null;
}
///
/// Gets and sets the property CacheControl.
///
/// An optional CacheControl
header that allows the caller to control the
/// object's cache behavior. Headers can be passed in as specified in the HTTP at https://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9.
///
///
///
/// Headers with a custom user-defined value are also accepted.
///
///
public string CacheControl
{
get { return this._cacheControl; }
set { this._cacheControl = value; }
}
// Check to see if CacheControl property is set
internal bool IsSetCacheControl()
{
return this._cacheControl != null;
}
///
/// Gets and sets the property ContentType.
///
/// The content type of the object.
///
///
public string ContentType
{
get { return this._contentType; }
set { this._contentType = value; }
}
// Check to see if ContentType property is set
internal bool IsSetContentType()
{
return this._contentType != null;
}
///
/// Gets and sets the property Path.
///
/// The path (including the file name) where the object is stored in the container. Format:
/// <folder name>/<folder name>/<file name>
///
///
///
/// For example, to upload the file mlaw.avi
to the folder path premium\canada
/// in the container movies
, enter the path premium/canada/mlaw.avi
.
///
///
///
/// Do not include the container name in this path.
///
///
///
/// If the path includes any folders that don't exist yet, the service creates them. For
/// example, suppose you have an existing premium/usa
subfolder. If you specify
/// premium/canada
, the service creates a canada
subfolder in
/// the premium
folder. You then have two subfolders, usa
and
/// canada
, in the premium
folder.
///
///
///
/// There is no correlation between the path to the source and the path (folders) in the
/// container in AWS Elemental MediaStore.
///
///
///
/// For more information about folders and how they exist in a container, see the AWS
/// Elemental MediaStore User Guide.
///
///
///
/// The file name is the name that is assigned to the file that you upload. The file can
/// have the same name inside and outside of AWS Elemental MediaStore, or it can have
/// the same name. The file name can include or omit an extension.
///
///
[AWSProperty(Required=true, Min=1, Max=900)]
public string Path
{
get { return this._path; }
set { this._path = value; }
}
// Check to see if Path property is set
internal bool IsSetPath()
{
return this._path != null;
}
///
/// Gets and sets the property StorageClass.
///
/// Indicates the storage class of a Put
request. Defaults to high-performance
/// temporal storage class, and objects are persisted into durable storage shortly after
/// being received.
///
///
[AWSProperty(Min=1, Max=16)]
public StorageClass StorageClass
{
get { return this._storageClass; }
set { this._storageClass = value; }
}
// Check to see if StorageClass property is set
internal bool IsSetStorageClass()
{
return this._storageClass != null;
}
///
/// Gets and sets the property UploadAvailability.
///
/// Indicates the availability of an object while it is still uploading. If the value
/// is set to streaming
, the object is available for downloading after some
/// initial buffering but before the object is uploaded completely. If the value is set
/// to standard
, the object is available for downloading only when it is
/// uploaded completely. The default value for this header is standard
.
///
///
///
/// To use this header, you must also set the HTTP Transfer-Encoding
header
/// to chunked
.
///
///
[AWSProperty(Min=1, Max=16)]
public UploadAvailability UploadAvailability
{
get { return this._uploadAvailability; }
set { this._uploadAvailability = value; }
}
// Check to see if UploadAvailability property is set
internal bool IsSetUploadAvailability()
{
return this._uploadAvailability != null;
}
///
/// Get the signer to use for this request.
///
/// A signer for this request.
override protected AbstractAWSSigner CreateSigner()
{
return new AWS4Signer(false);
}
}
}