/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { namespace Lambda { namespace Model { /** */ class AWS_LAMBDA_API UpdateFunctionCodeRequest : public LambdaRequest { public: UpdateFunctionCodeRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "UpdateFunctionCode"; } Aws::String SerializePayload() const override; /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline const Aws::String& GetFunctionName() const{ return m_functionName; } /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline bool FunctionNameHasBeenSet() const { return m_functionNameHasBeenSet; } /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline void SetFunctionName(const Aws::String& value) { m_functionNameHasBeenSet = true; m_functionName = value; } /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline void SetFunctionName(Aws::String&& value) { m_functionNameHasBeenSet = true; m_functionName = std::move(value); } /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline void SetFunctionName(const char* value) { m_functionNameHasBeenSet = true; m_functionName.assign(value); } /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline UpdateFunctionCodeRequest& WithFunctionName(const Aws::String& value) { SetFunctionName(value); return *this;} /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline UpdateFunctionCodeRequest& WithFunctionName(Aws::String&& value) { SetFunctionName(std::move(value)); return *this;} /** *

The name of the Lambda function.

Name formats *

  • Function name - my-function.

  • *
  • Function ARN - * arn:aws:lambda:us-west-2:123456789012:function:my-function.

    *
  • Partial ARN - * 123456789012:function:my-function.

The length * constraint applies only to the full ARN. If you specify only the function name, * it is limited to 64 characters in length.

*/ inline UpdateFunctionCodeRequest& WithFunctionName(const char* value) { SetFunctionName(value); return *this;} /** *

The base64-encoded contents of the deployment package. AWS SDK and AWS CLI * clients handle the encoding for you.

*/ inline const Aws::Utils::CryptoBuffer& GetZipFile() const{ return m_zipFile; } /** *

The base64-encoded contents of the deployment package. AWS SDK and AWS CLI * clients handle the encoding for you.

*/ inline bool ZipFileHasBeenSet() const { return m_zipFileHasBeenSet; } /** *

The base64-encoded contents of the deployment package. AWS SDK and AWS CLI * clients handle the encoding for you.

*/ inline void SetZipFile(const Aws::Utils::CryptoBuffer& value) { m_zipFileHasBeenSet = true; m_zipFile = value; } /** *

The base64-encoded contents of the deployment package. AWS SDK and AWS CLI * clients handle the encoding for you.

*/ inline void SetZipFile(Aws::Utils::CryptoBuffer&& value) { m_zipFileHasBeenSet = true; m_zipFile = std::move(value); } /** *

The base64-encoded contents of the deployment package. AWS SDK and AWS CLI * clients handle the encoding for you.

*/ inline UpdateFunctionCodeRequest& WithZipFile(const Aws::Utils::CryptoBuffer& value) { SetZipFile(value); return *this;} /** *

The base64-encoded contents of the deployment package. AWS SDK and AWS CLI * clients handle the encoding for you.

*/ inline UpdateFunctionCodeRequest& WithZipFile(Aws::Utils::CryptoBuffer&& value) { SetZipFile(std::move(value)); return *this;} /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline const Aws::String& GetS3Bucket() const{ return m_s3Bucket; } /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline bool S3BucketHasBeenSet() const { return m_s3BucketHasBeenSet; } /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline void SetS3Bucket(const Aws::String& value) { m_s3BucketHasBeenSet = true; m_s3Bucket = value; } /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline void SetS3Bucket(Aws::String&& value) { m_s3BucketHasBeenSet = true; m_s3Bucket = std::move(value); } /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline void SetS3Bucket(const char* value) { m_s3BucketHasBeenSet = true; m_s3Bucket.assign(value); } /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline UpdateFunctionCodeRequest& WithS3Bucket(const Aws::String& value) { SetS3Bucket(value); return *this;} /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline UpdateFunctionCodeRequest& WithS3Bucket(Aws::String&& value) { SetS3Bucket(std::move(value)); return *this;} /** *

An Amazon S3 bucket in the same AWS Region as your function. The bucket can * be in a different AWS account.

*/ inline UpdateFunctionCodeRequest& WithS3Bucket(const char* value) { SetS3Bucket(value); return *this;} /** *

The Amazon S3 key of the deployment package.

*/ inline const Aws::String& GetS3Key() const{ return m_s3Key; } /** *

The Amazon S3 key of the deployment package.

*/ inline bool S3KeyHasBeenSet() const { return m_s3KeyHasBeenSet; } /** *

The Amazon S3 key of the deployment package.

*/ inline void SetS3Key(const Aws::String& value) { m_s3KeyHasBeenSet = true; m_s3Key = value; } /** *

The Amazon S3 key of the deployment package.

*/ inline void SetS3Key(Aws::String&& value) { m_s3KeyHasBeenSet = true; m_s3Key = std::move(value); } /** *

The Amazon S3 key of the deployment package.

*/ inline void SetS3Key(const char* value) { m_s3KeyHasBeenSet = true; m_s3Key.assign(value); } /** *

The Amazon S3 key of the deployment package.

*/ inline UpdateFunctionCodeRequest& WithS3Key(const Aws::String& value) { SetS3Key(value); return *this;} /** *

The Amazon S3 key of the deployment package.

*/ inline UpdateFunctionCodeRequest& WithS3Key(Aws::String&& value) { SetS3Key(std::move(value)); return *this;} /** *

The Amazon S3 key of the deployment package.

*/ inline UpdateFunctionCodeRequest& WithS3Key(const char* value) { SetS3Key(value); return *this;} /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline const Aws::String& GetS3ObjectVersion() const{ return m_s3ObjectVersion; } /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline bool S3ObjectVersionHasBeenSet() const { return m_s3ObjectVersionHasBeenSet; } /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline void SetS3ObjectVersion(const Aws::String& value) { m_s3ObjectVersionHasBeenSet = true; m_s3ObjectVersion = value; } /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline void SetS3ObjectVersion(Aws::String&& value) { m_s3ObjectVersionHasBeenSet = true; m_s3ObjectVersion = std::move(value); } /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline void SetS3ObjectVersion(const char* value) { m_s3ObjectVersionHasBeenSet = true; m_s3ObjectVersion.assign(value); } /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline UpdateFunctionCodeRequest& WithS3ObjectVersion(const Aws::String& value) { SetS3ObjectVersion(value); return *this;} /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline UpdateFunctionCodeRequest& WithS3ObjectVersion(Aws::String&& value) { SetS3ObjectVersion(std::move(value)); return *this;} /** *

For versioned objects, the version of the deployment package object to * use.

*/ inline UpdateFunctionCodeRequest& WithS3ObjectVersion(const char* value) { SetS3ObjectVersion(value); return *this;} /** *

Set to true to publish a new version of the function after updating the code. * This has the same effect as calling PublishVersion separately.

*/ inline bool GetPublish() const{ return m_publish; } /** *

Set to true to publish a new version of the function after updating the code. * This has the same effect as calling PublishVersion separately.

*/ inline bool PublishHasBeenSet() const { return m_publishHasBeenSet; } /** *

Set to true to publish a new version of the function after updating the code. * This has the same effect as calling PublishVersion separately.

*/ inline void SetPublish(bool value) { m_publishHasBeenSet = true; m_publish = value; } /** *

Set to true to publish a new version of the function after updating the code. * This has the same effect as calling PublishVersion separately.

*/ inline UpdateFunctionCodeRequest& WithPublish(bool value) { SetPublish(value); return *this;} /** *

Set to true to validate the request parameters and access permissions without * modifying the function code.

*/ inline bool GetDryRun() const{ return m_dryRun; } /** *

Set to true to validate the request parameters and access permissions without * modifying the function code.

*/ inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; } /** *

Set to true to validate the request parameters and access permissions without * modifying the function code.

*/ inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; } /** *

Set to true to validate the request parameters and access permissions without * modifying the function code.

*/ inline UpdateFunctionCodeRequest& WithDryRun(bool value) { SetDryRun(value); return *this;} /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline const Aws::String& GetRevisionId() const{ return m_revisionId; } /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline bool RevisionIdHasBeenSet() const { return m_revisionIdHasBeenSet; } /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline void SetRevisionId(const Aws::String& value) { m_revisionIdHasBeenSet = true; m_revisionId = value; } /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline void SetRevisionId(Aws::String&& value) { m_revisionIdHasBeenSet = true; m_revisionId = std::move(value); } /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline void SetRevisionId(const char* value) { m_revisionIdHasBeenSet = true; m_revisionId.assign(value); } /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline UpdateFunctionCodeRequest& WithRevisionId(const Aws::String& value) { SetRevisionId(value); return *this;} /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline UpdateFunctionCodeRequest& WithRevisionId(Aws::String&& value) { SetRevisionId(std::move(value)); return *this;} /** *

Only update the function if the revision ID matches the ID that's specified. * Use this option to avoid modifying a function that has changed since you last * read it.

*/ inline UpdateFunctionCodeRequest& WithRevisionId(const char* value) { SetRevisionId(value); return *this;} private: Aws::String m_functionName; bool m_functionNameHasBeenSet; Aws::Utils::CryptoBuffer m_zipFile; bool m_zipFileHasBeenSet; Aws::String m_s3Bucket; bool m_s3BucketHasBeenSet; Aws::String m_s3Key; bool m_s3KeyHasBeenSet; Aws::String m_s3ObjectVersion; bool m_s3ObjectVersionHasBeenSet; bool m_publish; bool m_publishHasBeenSet; bool m_dryRun; bool m_dryRunHasBeenSet; Aws::String m_revisionId; bool m_revisionIdHasBeenSet; }; } // namespace Model } // namespace Lambda } // namespace Aws