Class: AWSCDK::CodeBuild::BucketCacheOptions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::CodeBuild::BucketCacheOptions
- Defined in:
- code_build/bucket_cache_options.rb
Instance Attribute Summary collapse
-
#cache_namespace ⇒ String?
readonly
Defines the scope of the cache.
-
#prefix ⇒ String?
readonly
The prefix to use to store the cache in the bucket.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(cache_namespace: nil, prefix: nil) ⇒ BucketCacheOptions
constructor
A new instance of BucketCacheOptions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(cache_namespace: nil, prefix: nil) ⇒ BucketCacheOptions
Returns a new instance of BucketCacheOptions.
8 9 10 11 12 13 |
# File 'code_build/bucket_cache_options.rb', line 8 def initialize(cache_namespace: nil, prefix: nil) @cache_namespace = cache_namespace Jsii::Type.check_type(@cache_namespace, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "cacheNamespace") unless @cache_namespace.nil? @prefix = prefix Jsii::Type.check_type(@prefix, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "prefix") unless @prefix.nil? end |
Instance Attribute Details
#cache_namespace ⇒ String? (readonly)
Note:
Default: undefined - No cache namespace, which means that the cache is not shared across multiple projects.
Defines the scope of the cache.
You can use this namespace to share a cache across multiple projects.
22 23 24 |
# File 'code_build/bucket_cache_options.rb', line 22 def cache_namespace @cache_namespace end |
#prefix ⇒ String? (readonly)
The prefix to use to store the cache in the bucket.
26 27 28 |
# File 'code_build/bucket_cache_options.rb', line 26 def prefix @prefix end |
Class Method Details
.jsii_properties ⇒ Object
28 29 30 31 32 33 |
# File 'code_build/bucket_cache_options.rb', line 28 def self.jsii_properties { :cache_namespace => "cacheNamespace", :prefix => "prefix", } end |
Instance Method Details
#to_jsii ⇒ Object
35 36 37 38 39 40 41 42 |
# File 'code_build/bucket_cache_options.rb', line 35 def to_jsii result = {} result.merge!({ "cacheNamespace" => @cache_namespace, "prefix" => @prefix, }) result.compact end |