Class: Google::Storage::Property::BucketRuleArray

Inherits:
Array
  • Object
show all
Defined in:
lib/google/storage/property/bucket_rule.rb

Overview

A Puppet property that holds an integer

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Array

#match_all?, match_all_array

Methods inherited from Base

#insync?

Class Method Details

.api_munge(value) ⇒ Object

Used for parsing GCP API responses



140
141
142
143
144
145
# File 'lib/google/storage/property/bucket_rule.rb', line 140

def self.api_munge(value)
  return if value.nil?
  return BucketRule.api_munge(value) \
    unless value.is_a?(::Array)
  value.map { |v| BucketRule.api_munge(v) }
end

.unsafe_munge(value) ⇒ Object

Used for parsing Puppet catalog



132
133
134
135
136
137
# File 'lib/google/storage/property/bucket_rule.rb', line 132

def self.unsafe_munge(value)
  return if value.nil?
  return BucketRule.unsafe_munge(value) \
    unless value.is_a?(::Array)
  value.map { |v| BucketRule.unsafe_munge(v) }
end

Instance Method Details

#unsafe_munge(value) ⇒ Object

Used for parsing Puppet catalog



127
128
129
# File 'lib/google/storage/property/bucket_rule.rb', line 127

def unsafe_munge(value)
  self.class.unsafe_munge(value)
end