/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace IoT { namespace Model { /** *

Describes a file to be associated with an OTA update.

See * Also:

AWS * API Reference

*/ class AWS_IOT_API OTAUpdateFile { public: OTAUpdateFile(); OTAUpdateFile(Aws::Utils::Json::JsonView jsonValue); OTAUpdateFile& operator=(Aws::Utils::Json::JsonView jsonValue); Aws::Utils::Json::JsonValue Jsonize() const; /** *

The name of the file.

*/ inline const Aws::String& GetFileName() const{ return m_fileName; } /** *

The name of the file.

*/ inline bool FileNameHasBeenSet() const { return m_fileNameHasBeenSet; } /** *

The name of the file.

*/ inline void SetFileName(const Aws::String& value) { m_fileNameHasBeenSet = true; m_fileName = value; } /** *

The name of the file.

*/ inline void SetFileName(Aws::String&& value) { m_fileNameHasBeenSet = true; m_fileName = std::move(value); } /** *

The name of the file.

*/ inline void SetFileName(const char* value) { m_fileNameHasBeenSet = true; m_fileName.assign(value); } /** *

The name of the file.

*/ inline OTAUpdateFile& WithFileName(const Aws::String& value) { SetFileName(value); return *this;} /** *

The name of the file.

*/ inline OTAUpdateFile& WithFileName(Aws::String&& value) { SetFileName(std::move(value)); return *this;} /** *

The name of the file.

*/ inline OTAUpdateFile& WithFileName(const char* value) { SetFileName(value); return *this;} /** *

The file version.

*/ inline const Aws::String& GetFileVersion() const{ return m_fileVersion; } /** *

The file version.

*/ inline bool FileVersionHasBeenSet() const { return m_fileVersionHasBeenSet; } /** *

The file version.

*/ inline void SetFileVersion(const Aws::String& value) { m_fileVersionHasBeenSet = true; m_fileVersion = value; } /** *

The file version.

*/ inline void SetFileVersion(Aws::String&& value) { m_fileVersionHasBeenSet = true; m_fileVersion = std::move(value); } /** *

The file version.

*/ inline void SetFileVersion(const char* value) { m_fileVersionHasBeenSet = true; m_fileVersion.assign(value); } /** *

The file version.

*/ inline OTAUpdateFile& WithFileVersion(const Aws::String& value) { SetFileVersion(value); return *this;} /** *

The file version.

*/ inline OTAUpdateFile& WithFileVersion(Aws::String&& value) { SetFileVersion(std::move(value)); return *this;} /** *

The file version.

*/ inline OTAUpdateFile& WithFileVersion(const char* value) { SetFileVersion(value); return *this;} /** *

The location of the updated firmware.

*/ inline const FileLocation& GetFileLocation() const{ return m_fileLocation; } /** *

The location of the updated firmware.

*/ inline bool FileLocationHasBeenSet() const { return m_fileLocationHasBeenSet; } /** *

The location of the updated firmware.

*/ inline void SetFileLocation(const FileLocation& value) { m_fileLocationHasBeenSet = true; m_fileLocation = value; } /** *

The location of the updated firmware.

*/ inline void SetFileLocation(FileLocation&& value) { m_fileLocationHasBeenSet = true; m_fileLocation = std::move(value); } /** *

The location of the updated firmware.

*/ inline OTAUpdateFile& WithFileLocation(const FileLocation& value) { SetFileLocation(value); return *this;} /** *

The location of the updated firmware.

*/ inline OTAUpdateFile& WithFileLocation(FileLocation&& value) { SetFileLocation(std::move(value)); return *this;} /** *

The code signing method of the file.

*/ inline const CodeSigning& GetCodeSigning() const{ return m_codeSigning; } /** *

The code signing method of the file.

*/ inline bool CodeSigningHasBeenSet() const { return m_codeSigningHasBeenSet; } /** *

The code signing method of the file.

*/ inline void SetCodeSigning(const CodeSigning& value) { m_codeSigningHasBeenSet = true; m_codeSigning = value; } /** *

The code signing method of the file.

*/ inline void SetCodeSigning(CodeSigning&& value) { m_codeSigningHasBeenSet = true; m_codeSigning = std::move(value); } /** *

The code signing method of the file.

*/ inline OTAUpdateFile& WithCodeSigning(const CodeSigning& value) { SetCodeSigning(value); return *this;} /** *

The code signing method of the file.

*/ inline OTAUpdateFile& WithCodeSigning(CodeSigning&& value) { SetCodeSigning(std::move(value)); return *this;} /** *

A list of name/attribute pairs.

*/ inline const Aws::Map& GetAttributes() const{ return m_attributes; } /** *

A list of name/attribute pairs.

*/ inline bool AttributesHasBeenSet() const { return m_attributesHasBeenSet; } /** *

A list of name/attribute pairs.

*/ inline void SetAttributes(const Aws::Map& value) { m_attributesHasBeenSet = true; m_attributes = value; } /** *

A list of name/attribute pairs.

*/ inline void SetAttributes(Aws::Map&& value) { m_attributesHasBeenSet = true; m_attributes = std::move(value); } /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& WithAttributes(const Aws::Map& value) { SetAttributes(value); return *this;} /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& WithAttributes(Aws::Map&& value) { SetAttributes(std::move(value)); return *this;} /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& AddAttributes(const Aws::String& key, const Aws::String& value) { m_attributesHasBeenSet = true; m_attributes.emplace(key, value); return *this; } /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& AddAttributes(Aws::String&& key, const Aws::String& value) { m_attributesHasBeenSet = true; m_attributes.emplace(std::move(key), value); return *this; } /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& AddAttributes(const Aws::String& key, Aws::String&& value) { m_attributesHasBeenSet = true; m_attributes.emplace(key, std::move(value)); return *this; } /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& AddAttributes(Aws::String&& key, Aws::String&& value) { m_attributesHasBeenSet = true; m_attributes.emplace(std::move(key), std::move(value)); return *this; } /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& AddAttributes(const char* key, Aws::String&& value) { m_attributesHasBeenSet = true; m_attributes.emplace(key, std::move(value)); return *this; } /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& AddAttributes(Aws::String&& key, const char* value) { m_attributesHasBeenSet = true; m_attributes.emplace(std::move(key), value); return *this; } /** *

A list of name/attribute pairs.

*/ inline OTAUpdateFile& AddAttributes(const char* key, const char* value) { m_attributesHasBeenSet = true; m_attributes.emplace(key, value); return *this; } private: Aws::String m_fileName; bool m_fileNameHasBeenSet; Aws::String m_fileVersion; bool m_fileVersionHasBeenSet; FileLocation m_fileLocation; bool m_fileLocationHasBeenSet; CodeSigning m_codeSigning; bool m_codeSigningHasBeenSet; Aws::Map m_attributes; bool m_attributesHasBeenSet; }; } // namespace Model } // namespace IoT } // namespace Aws