Class: CFPropertyList::CFArray
Overview
This class contains an array of values
Instance Attribute Summary
Attributes inherited from CFType
Instance Method Summary collapse
-
#initialize(val = []) ⇒ CFArray
constructor
create a new array CFType.
-
#to_binary(bplist) ⇒ Object
convert to binary.
-
#to_xml ⇒ Object
convert to XML.
Constructor Details
#initialize(val = []) ⇒ CFArray
create a new array CFType
185 186 187 |
# File 'lib/rbCFTypes.rb', line 185 def initialize(val=[]) @value = val end |
Instance Method Details
#to_binary(bplist) ⇒ Object
convert to binary
201 202 203 |
# File 'lib/rbCFTypes.rb', line 201 def to_binary(bplist) return bplist.array_to_binary(self) end |
#to_xml ⇒ Object
convert to XML
190 191 192 193 194 195 196 197 198 |
# File 'lib/rbCFTypes.rb', line 190 def to_xml n = LibXML::XML::Node.new('array') @value.each do |v| n << v.to_xml end return n end |