@Generated(value="jsii-pacmak/1.71.0 (build f1f58ae)", date="2022-12-07T17:24:34.371Z") @Stability(value=Stable) public class CfnRepositoryAssociation extends CfnResource implements IInspectable
This resource configures how Amazon CodeGuru Reviewer retrieves the source code to be reviewed. You can use an AWS CloudFormation template to create an association with the following repository types:
You cannot use a CloudFormation template to create an association with a GitHub repository.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.codegurureviewer.*;
CfnRepositoryAssociation cfnRepositoryAssociation = CfnRepositoryAssociation.Builder.create(this, "MyCfnRepositoryAssociation")
.name("name")
.type("type")
// the properties below are optional
.bucketName("bucketName")
.connectionArn("connectionArn")
.owner("owner")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
| Modifier and Type | Class and Description |
|---|---|
static class |
CfnRepositoryAssociation.Builder
A fluent builder for
CfnRepositoryAssociation. |
software.amazon.jsii.JsiiObject.InitializationModeIInspectable.Jsii$Default, IInspectable.Jsii$ProxyIConstruct.Jsii$Default| Modifier and Type | Field and Description |
|---|---|
static String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
| Modifier | Constructor and Description |
|---|---|
|
CfnRepositoryAssociation(Construct scope,
String id,
CfnRepositoryAssociationProps props)
Create a new `AWS::CodeGuruReviewer::RepositoryAssociation`.
|
protected |
CfnRepositoryAssociation(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnRepositoryAssociation(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
String |
getAttrAssociationArn()
The Amazon Resource Name (ARN) of the [`RepositoryAssociation`](https://docs.aws.amazon.com/codeguru/latest/reviewer-api/API_RepositoryAssociation.html) object.
|
String |
getBucketName()
The name of the bucket.
|
protected Map<String,Object> |
getCfnProperties() |
String |
getConnectionArn()
The Amazon Resource Name (ARN) of an AWS CodeStar Connections connection.
|
String |
getName()
The name of the repository.
|
String |
getOwner()
The owner of the repository.
|
TagManager |
getTags()
An array of key-value pairs used to tag an associated repository.
|
String |
getType()
The type of repository that contains the source code to be reviewed.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected Map<String,Object> |
renderProperties(Map<String,Object> props) |
void |
setBucketName(String value)
The name of the bucket.
|
void |
setConnectionArn(String value)
The Amazon Resource Name (ARN) of an AWS CodeStar Connections connection.
|
void |
setName(String value)
The name of the repository.
|
void |
setOwner(String value)
The owner of the repository.
|
void |
setType(String value)
The type of repository that contains the source code to be reviewed.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validatePropertiesgetRefgetCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdgetNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validatejsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Stable) public static final String CFN_RESOURCE_TYPE_NAME
protected CfnRepositoryAssociation(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnRepositoryAssociation(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public CfnRepositoryAssociation(@NotNull
Construct scope,
@NotNull
String id,
@NotNull
CfnRepositoryAssociationProps props)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.props - - resource properties. This parameter is required.@Stability(value=Stable)
public void inspect(@NotNull
TreeInspector inspector)
inspect in interface IInspectableinspector - - tree inspector to collect and process attributes. This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
renderProperties in class CfnResourceprops - This parameter is required.@Stability(value=Stable) @NotNull public String getAttrAssociationArn()
@Stability(value=Stable) @NotNull protected Map<String,Object> getCfnProperties()
getCfnProperties in class CfnResource@Stability(value=Stable) @NotNull public TagManager getTags()
A tag is a custom attribute label with two parts:
CostCenter , Environment , Project , or Secret ). Tag keys are case sensitive.111122223333 , Production , or a team name). Omitting the tag value is the same as using an empty string. Like tag keys, tag values are case sensitive.@Stability(value=Stable) @NotNull public String getName()
@Stability(value=Stable)
public void setName(@NotNull
String value)
@Stability(value=Stable) @NotNull public String getType()
CodeCommitBitbucketGitHubEnterpriseServerS3Bucket@Stability(value=Stable)
public void setType(@NotNull
String value)
CodeCommitBitbucketGitHubEnterpriseServerS3Bucket@Stability(value=Stable) @Nullable public String getBucketName()
This is required for your S3Bucket repositoryThe name must start with the prefix, codeguru-reviewer-* .
@Stability(value=Stable)
public void setBucketName(@Nullable
String value)
This is required for your S3Bucket repositoryThe name must start with the prefix, codeguru-reviewer-* .
@Stability(value=Stable) @Nullable public String getConnectionArn()
Its format is arn:aws:codestar-connections:region-id:aws-account_id:connection/connection-id . For more information, see Connection in the AWS CodeStar Connections API Reference .
ConnectionArn must be specified for Bitbucket and GitHub Enterprise Server repositories. It has no effect if it is specified for an AWS CodeCommit repository.
@Stability(value=Stable)
public void setConnectionArn(@Nullable
String value)
Its format is arn:aws:codestar-connections:region-id:aws-account_id:connection/connection-id . For more information, see Connection in the AWS CodeStar Connections API Reference .
ConnectionArn must be specified for Bitbucket and GitHub Enterprise Server repositories. It has no effect if it is specified for an AWS CodeCommit repository.
@Stability(value=Stable) @Nullable public String getOwner()
For a GitHub Enterprise Server or Bitbucket repository, this is the username for the account that owns the repository.
Owner must be specified for Bitbucket and GitHub Enterprise Server repositories. It has no effect if it is specified for an AWS CodeCommit repository.
@Stability(value=Stable)
public void setOwner(@Nullable
String value)
For a GitHub Enterprise Server or Bitbucket repository, this is the username for the account that owns the repository.
Owner must be specified for Bitbucket and GitHub Enterprise Server repositories. It has no effect if it is specified for an AWS CodeCommit repository.
Copyright © 2022. All rights reserved.