Class: AWSCDK::CodeStar::CfnGitHubRepositoryProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
code_star/cfn_git_hub_repository_props.rb

Overview

Properties for defining a CfnGitHubRepository.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(repository_name:, repository_owner:, code: nil, connection_arn: nil, enable_issues: nil, is_private: nil, repository_access_token: nil, repository_description: nil) ⇒ CfnGitHubRepositoryProps

Returns a new instance of CfnGitHubRepositoryProps.

Parameters:

  • repository_name (String)

    The name of the repository you want to create in GitHub with CloudFormation stack creation.

  • repository_owner (String)

    The GitHub user name for the owner of the GitHub repository to be created.

  • code (AWSCDK::IResolvable, AWSCDK::CodeStar::CfnGitHubRepository::CodeProperty, nil) (defaults to: nil)

    Information about code to be committed to a repository after it is created in an CloudFormation stack.

  • connection_arn (String, nil) (defaults to: nil)
  • enable_issues (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    Indicates whether to enable issues for the GitHub repository.

  • is_private (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    Indicates whether the GitHub repository is a private repository.

  • repository_access_token (String, nil) (defaults to: nil)

    The GitHub user's personal access token for the GitHub repository.

  • repository_description (String, nil) (defaults to: nil)

    A comment or description about the new repository.



17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# File 'code_star/cfn_git_hub_repository_props.rb', line 17

def initialize(repository_name:, repository_owner:, code: nil, connection_arn: nil, enable_issues: nil, is_private: nil, repository_access_token: nil, repository_description: nil)
  @repository_name = repository_name
  Jsii::Type.check_type(@repository_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "repositoryName")
  @repository_owner = repository_owner
  Jsii::Type.check_type(@repository_owner, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "repositoryOwner")
  @code = code.is_a?(Hash) ? ::AWSCDK::CodeStar::CfnGitHubRepository::CodeProperty.new(**code.transform_keys(&:to_sym)) : code
  Jsii::Type.check_type(@code, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19jb2Rlc3Rhci5DZm5HaXRIdWJSZXBvc2l0b3J5LkNvZGVQcm9wZXJ0eSJ9XX19")), "code") unless @code.nil?
  @connection_arn = connection_arn
  Jsii::Type.check_type(@connection_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "connectionArn") unless @connection_arn.nil?
  @enable_issues = enable_issues
  Jsii::Type.check_type(@enable_issues, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "enableIssues") unless @enable_issues.nil?
  @is_private = is_private
  Jsii::Type.check_type(@is_private, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "isPrivate") unless @is_private.nil?
  @repository_access_token = repository_access_token
  Jsii::Type.check_type(@repository_access_token, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "repositoryAccessToken") unless @repository_access_token.nil?
  @repository_description = repository_description
  Jsii::Type.check_type(@repository_description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "repositoryDescription") unless @repository_description.nil?
end

Instance Attribute Details

#codeAWSCDK::IResolvable, ... (readonly)

Information about code to be committed to a repository after it is created in an CloudFormation stack.



52
53
54
# File 'code_star/cfn_git_hub_repository_props.rb', line 52

def code
  @code
end

#connection_arnString? (readonly)



55
56
57
# File 'code_star/cfn_git_hub_repository_props.rb', line 55

def connection_arn
  @connection_arn
end

#enable_issuesBoolean, ... (readonly)

Indicates whether to enable issues for the GitHub repository.

You can use GitHub issues to track information and bugs for your repository.



62
63
64
# File 'code_star/cfn_git_hub_repository_props.rb', line 62

def enable_issues
  @enable_issues
end

#is_privateBoolean, ... (readonly)

Indicates whether the GitHub repository is a private repository.

If so, you choose who can see and commit to this repository.



69
70
71
# File 'code_star/cfn_git_hub_repository_props.rb', line 69

def is_private
  @is_private
end

#repository_access_tokenString? (readonly)

The GitHub user's personal access token for the GitHub repository.



74
75
76
# File 'code_star/cfn_git_hub_repository_props.rb', line 74

def repository_access_token
  @repository_access_token
end

#repository_descriptionString? (readonly)

A comment or description about the new repository.

This description is displayed in GitHub after the repository is created.



81
82
83
# File 'code_star/cfn_git_hub_repository_props.rb', line 81

def repository_description
  @repository_description
end

#repository_nameString (readonly)

The name of the repository you want to create in GitHub with CloudFormation stack creation.



40
41
42
# File 'code_star/cfn_git_hub_repository_props.rb', line 40

def repository_name
  @repository_name
end

#repository_ownerString (readonly)

The GitHub user name for the owner of the GitHub repository to be created.

If this repository should be owned by a GitHub organization, provide its name.



47
48
49
# File 'code_star/cfn_git_hub_repository_props.rb', line 47

def repository_owner
  @repository_owner
end

Class Method Details

.jsii_propertiesObject



83
84
85
86
87
88
89
90
91
92
93
94
# File 'code_star/cfn_git_hub_repository_props.rb', line 83

def self.jsii_properties
  {
    :repository_name => "repositoryName",
    :repository_owner => "repositoryOwner",
    :code => "code",
    :connection_arn => "connectionArn",
    :enable_issues => "enableIssues",
    :is_private => "isPrivate",
    :repository_access_token => "repositoryAccessToken",
    :repository_description => "repositoryDescription",
  }
end

Instance Method Details

#to_jsiiObject



96
97
98
99
100
101
102
103
104
105
106
107
108
109
# File 'code_star/cfn_git_hub_repository_props.rb', line 96

def to_jsii
  result = {}
  result.merge!({
    "repositoryName" => @repository_name,
    "repositoryOwner" => @repository_owner,
    "code" => @code,
    "connectionArn" => @connection_arn,
    "enableIssues" => @enable_issues,
    "isPrivate" => @is_private,
    "repositoryAccessToken" => @repository_access_token,
    "repositoryDescription" => @repository_description,
  })
  result.compact
end