Class: AWSCDK::CodeBuild::Cache
- Inherits:
-
Jsii::Object
- Object
- Jsii::Object
- AWSCDK::CodeBuild::Cache
- Defined in:
- code_build/cache.rb
Overview
Cache options for CodeBuild Project.
A cache can store reusable pieces of your build environment and use them across multiple builds.
Class Method Summary collapse
-
.bucket(bucket, options = nil) ⇒ AWSCDK::CodeBuild::Cache
Create an S3 caching strategy.
- .jsii_overridable_methods ⇒ Object
-
.local(*modes) ⇒ AWSCDK::CodeBuild::Cache
Create a local caching strategy.
- .none ⇒ AWSCDK::CodeBuild::Cache
Instance Method Summary collapse
-
#initialize ⇒ Cache
constructor
A new instance of Cache.
Constructor Details
#initialize ⇒ Cache
Returns a new instance of Cache.
12 13 14 |
# File 'code_build/cache.rb', line 12 def initialize Jsii::Object.instance_method(:initialize).bind(self).call end |
Class Method Details
.bucket(bucket, options = nil) ⇒ AWSCDK::CodeBuild::Cache
Create an S3 caching strategy.
26 27 28 29 30 31 |
# File 'code_build/cache.rb', line 26 def self.bucket(bucket, = nil) Jsii::Type.check_type(bucket, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfczMuSUJ1Y2tldCJ9")), "bucket") = .is_a?(Hash) ? ::AWSCDK::CodeBuild::BucketCacheOptions.new(**.transform_keys(&:to_sym)) : Jsii::Type.check_type(, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY29kZWJ1aWxkLkJ1Y2tldENhY2hlT3B0aW9ucyJ9")), "options") unless .nil? Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_codebuild.Cache", "bucket", [bucket, ]) end |
.jsii_overridable_methods ⇒ Object
16 17 18 19 |
# File 'code_build/cache.rb', line 16 def self.jsii_overridable_methods { } end |
.local(*modes) ⇒ AWSCDK::CodeBuild::Cache
Create a local caching strategy.
37 38 39 40 41 42 |
# File 'code_build/cache.rb', line 37 def self.local(*modes) modes.each_with_index do |item, index| Jsii::Type.check_type(item, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY29kZWJ1aWxkLkxvY2FsQ2FjaGVNb2RlIn0=")), "modes[#{index}]") end Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_codebuild.Cache", "local", [*modes]) end |
.none ⇒ AWSCDK::CodeBuild::Cache
45 46 47 |
# File 'code_build/cache.rb', line 45 def self.none() Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_codebuild.Cache", "none", []) end |