Class CfnRepository
A CloudFormation AWS::CodeCommit::Repository
.
Inherited Members
Namespace: Amazon.CDK.AWS.CodeCommit
Assembly: Amazon.CDK.AWS.CodeCommit.dll
Syntax (csharp)
public class CfnRepository : CfnResource, IConstruct, IDependable, IInspectable
Syntax (vb)
Public Class CfnRepository
Inherits CfnResource
Implements IConstruct, IDependable, IInspectable
Remarks
Creates a new, empty repository.
CloudformationResource: AWS::CodeCommit::Repository
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CodeCommit;
var cfnRepository = new CfnRepository(this, "MyCfnRepository", new CfnRepositoryProps {
RepositoryName = "repositoryName",
// the properties below are optional
Code = new CodeProperty {
S3 = new S3Property {
Bucket = "bucket",
Key = "key",
// the properties below are optional
ObjectVersion = "objectVersion"
},
// the properties below are optional
BranchName = "branchName"
},
RepositoryDescription = "repositoryDescription",
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} },
Triggers = new [] { new RepositoryTriggerProperty {
DestinationArn = "destinationArn",
Events = new [] { "events" },
Name = "name",
// the properties below are optional
Branches = new [] { "branches" },
CustomData = "customData"
} }
});
Synopsis
Constructors
CfnRepository(Construct, String, ICfnRepositoryProps) | Create a new |
CfnRepository(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
CfnRepository(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Properties
AttrArn | When you pass the logical ID of this resource, the function returns the Amazon Resource Name (ARN) of the repository. |
AttrCloneUrlHttp | When you pass the logical ID of this resource, the function returns the URL to use for cloning the repository over HTTPS. |
AttrCloneUrlSsh | When you pass the logical ID of this resource, the function returns the URL to use for cloning the repository over SSH. |
AttrName | When you pass the logical ID of this resource, the function returns the repository's name. |
CFN_RESOURCE_TYPE_NAME | The CloudFormation resource type name for this resource class. |
CfnProperties | |
Code | Information about code to be committed to a repository after it is created in an AWS CloudFormation stack. |
RepositoryDescription | A comment or description about the new repository. |
RepositoryName | The name of the new repository to be created. |
Tags | One or more tag key-value pairs to use when tagging this repository. |
Triggers | The JSON block of configuration information for each trigger. |
Methods
Inspect(TreeInspector) | Examines the CloudFormation resource and discloses attributes. |
RenderProperties(IDictionary<String, Object>) |
Constructors
CfnRepository(Construct, String, ICfnRepositoryProps)
Create a new AWS::CodeCommit::Repository
.
public CfnRepository(Construct scope, string id, ICfnRepositoryProps props)
Parameters
- scope Construct
- scope in which this resource is defined.
- id System.String
- scoped id of the resource.
- props ICfnRepositoryProps
- resource properties.
CfnRepository(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected CfnRepository(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
CfnRepository(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected CfnRepository(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Properties
AttrArn
When you pass the logical ID of this resource, the function returns the Amazon Resource Name (ARN) of the repository.
public virtual string AttrArn { get; }
Property Value
System.String
Remarks
CloudformationAttribute: Arn
AttrCloneUrlHttp
When you pass the logical ID of this resource, the function returns the URL to use for cloning the repository over HTTPS.
public virtual string AttrCloneUrlHttp { get; }
Property Value
System.String
Remarks
CloudformationAttribute: CloneUrlHttp
AttrCloneUrlSsh
When you pass the logical ID of this resource, the function returns the URL to use for cloning the repository over SSH.
public virtual string AttrCloneUrlSsh { get; }
Property Value
System.String
Remarks
CloudformationAttribute: CloneUrlSsh
AttrName
When you pass the logical ID of this resource, the function returns the repository's name.
public virtual string AttrName { get; }
Property Value
System.String
Remarks
CloudformationAttribute: Name
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
public static string CFN_RESOURCE_TYPE_NAME { get; }
Property Value
System.String
CfnProperties
protected override IDictionary<string, object> CfnProperties { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.Object>
Overrides
Code
Information about code to be committed to a repository after it is created in an AWS CloudFormation stack.
public virtual object Code { get; set; }
Property Value
System.Object
Remarks
Information about code is only used in resource creation. Updates to a stack will not reflect changes made to code properties after initial resource creation.
You can only use this property to add code when creating a repository with a AWS CloudFormation template at creation time. This property cannot be used for updating code to an existing repository.
RepositoryDescription
A comment or description about the new repository.
public virtual string RepositoryDescription { get; set; }
Property Value
System.String
Remarks
The description field for a repository accepts all HTML characters and all valid Unicode characters. Applications that do not HTML-encode the description and display it in a webpage can expose users to potentially malicious code. Make sure that you HTML-encode the description field in any application that uses this API to display the repository description on a webpage.
RepositoryName
The name of the new repository to be created.
public virtual string RepositoryName { get; set; }
Property Value
System.String
Remarks
The repository name must be unique across the calling AWS account . Repository names are limited to 100 alphanumeric, dash, and underscore characters, and cannot include certain characters. For more information about the limits on repository names, see Quotas in the AWS CodeCommit User Guide . The suffix .git is prohibited.
Tags
One or more tag key-value pairs to use when tagging this repository.
public virtual TagManager Tags { get; }
Property Value
Remarks
Triggers
The JSON block of configuration information for each trigger.
public virtual object Triggers { get; set; }
Property Value
System.Object
Remarks
Methods
Inspect(TreeInspector)
Examines the CloudFormation resource and discloses attributes.
public virtual void Inspect(TreeInspector inspector)
Parameters
- inspector TreeInspector
- tree inspector to collect and process attributes.
RenderProperties(IDictionary<String, Object>)
protected override IDictionary<string, object> RenderProperties(IDictionary<string, object> props)
Parameters
- props System.Collections.Generic.IDictionary<System.String, System.Object>
Returns
System.Collections.Generic.IDictionary<System.String, System.Object>