Show / Hide Table of Contents

Class AwsConverters

The static AwsConverters class provides convenience methods for converting Amazon Resource Name (ARN) into an alternative representation more suitable for their respective clients.

Inheritance
System.Object
AwsConverters
Namespace: LambdaSharp
Assembly: LambdaSharp.dll
Syntax
public static class AwsConverters

Methods

ConvertBucketArnToName(String)

Convert an S3 bucket ARN into a bucket name.

Declaration
public static string ConvertBucketArnToName(string arn)
Parameters
Type Name Description
System.String arn

S3 bucket ARN.

Returns
Type Description
System.String

S3 bucket name.

ConvertDynamoDBArnToName(String)

Convert a DynamoDB table ARN into a table name.

Declaration
public static string ConvertDynamoDBArnToName(string arn)
Parameters
Type Name Description
System.String arn

DynamoDB table ARN.

Returns
Type Description
System.String

DynamoDB table name.

ConvertFunctionArnToName(String)

Convert a Lambda function ARN into a function name.

Declaration
public static string ConvertFunctionArnToName(string arn)
Parameters
Type Name Description
System.String arn

Lambda function ARN.

Returns
Type Description
System.String

Lambda function name.

ConvertQueueArnToUrl(String)

Convert an SQS queue ARN into a queue URL.

Declaration
public static string ConvertQueueArnToUrl(string arn)
Parameters
Type Name Description
System.String arn

SQS queue ARN.

Returns
Type Description
System.String

SQS queue URL.

ReadDynamoDBTableName(LambdaConfig, String)

Read a DynamoDB table ARN from LambdaConfig and convert it to a table name.

Declaration
public static string ReadDynamoDBTableName(this LambdaConfig config, string key)
Parameters
Type Name Description
LambdaConfig config

The LambdaConfig instance.

System.String key

The key to read.

Returns
Type Description
System.String

DynamoDB table name.

ReadLambdaFunctionName(LambdaConfig, String)

Read a Lambda function ARN from LambdaConfig and convert it to a function name.

Declaration
public static string ReadLambdaFunctionName(this LambdaConfig config, string key)
Parameters
Type Name Description
LambdaConfig config

The LambdaConfig instance.

System.String key

The key to read.

Returns
Type Description
System.String

Lambda function name.

ReadS3BucketName(LambdaConfig, String)

Read an S3 bucket ARN from LambdaConfig and convert it to a bucket name.

Declaration
public static string ReadS3BucketName(this LambdaConfig config, string key)
Parameters
Type Name Description
LambdaConfig config

The LambdaConfig instance.

System.String key

The key to read.

Returns
Type Description
System.String

S3 bucket name.

ReadSqsQueueUrl(LambdaConfig, String)

Read an SQS queue ARN from LambdaConfig and convert it to a queue URL.

Declaration
public static string ReadSqsQueueUrl(this LambdaConfig config, string key)
Parameters
Type Name Description
LambdaConfig config

The LambdaConfig instance.

System.String key

The key to read.

Returns
Type Description
System.String

SQS queue URL.

ToStream(String)

The ToStream(String) extension method converts a string value to a UTF-8 encoded memory stream.

Declaration
public static Stream ToStream(this string value)
Parameters
Type Name Description
System.String value

The System.String value.

Returns
Type Description
System.IO.Stream

The UTF-8 encoded stream.

In This Article
Back to top Generated by DocFX