Class: Puppet::Util::TagSet
Class Method Summary
collapse
Instance Method Summary
collapse
included, #mime, #render, #support_format?, #to_msgpack
Class Method Details
.from_data_hash(data) ⇒ Object
15
16
17
|
# File 'lib/puppet/util/tag_set.rb', line 15
def self.from_data_hash(data)
self.new(data)
end
|
.from_pson(data) ⇒ Object
19
20
21
22
|
# File 'lib/puppet/util/tag_set.rb', line 19
def self.from_pson(data)
Puppet.deprecation_warning("from_pson is being removed in favour of from_data_hash.")
self.from_data_hash(data)
end
|
.from_yaml(yaml) ⇒ Object
7
8
9
|
# File 'lib/puppet/util/tag_set.rb', line 7
def self.from_yaml(yaml)
self.new(YAML.load(yaml))
end
|
Instance Method Details
#join(*args) ⇒ Object
38
39
40
|
# File 'lib/puppet/util/tag_set.rb', line 38
def join(*args)
to_a.join(*args)
end
|
#to_data_hash ⇒ Object
24
25
26
|
# File 'lib/puppet/util/tag_set.rb', line 24
def to_data_hash
to_a
end
|
#to_pson(*args) ⇒ Object
28
29
30
|
# File 'lib/puppet/util/tag_set.rb', line 28
def to_pson(*args)
to_data_hash.to_pson
end
|
11
12
13
|
# File 'lib/puppet/util/tag_set.rb', line 11
def to_yaml
@hash.keys.to_yaml
end
|
#to_zaml(z) ⇒ Object
this makes puppet serialize it as an array for backwards compatibility
34
35
36
|
# File 'lib/puppet/util/tag_set.rb', line 34
def to_zaml(z)
to_data_hash.to_zaml(z)
end
|