Methods

Plist

—###########################################################

 Copyright 2006, Ben Bleything <ben@bleything.net> and    #
 Patrick May <patrick@hexane.org>               #
                              #
 Distributed under the MIT license.             #
                                                             

++

 Plist parses Mac OS X xml property list files into ruby data structures.

 === Load a plist file
 This is the main point of the library:

   r = Plist::parse_xml( filename_or_xml )

—###########################################################

 Copyright 2006, Ben Bleything <ben@bleything.net> and    #
 Patrick May <patrick@hexane.org>               #
                              #
 Distributed under the MIT license.             #
                                                             

++

 See Plist::Emit.

Constants

VERSION

Public Class Methods

parse_xml( filename_or_xml ) click to toggle source

Note that I don’t use these two elements much:

 + Date elements are returned as DateTime objects.
 + Data elements are implemented as Tempfiles

Plist::parse_xml will blow up if it encounters a data element. If you encounter such an error, or if you have a Date element which can’t be parsed into a Time object, please send your plist file to plist@hexane.org so that I can implement the proper support.

    # File lib/facter/util/plist/parser.rb, line 24
24:   def Plist::parse_xml( filename_or_xml )
25:     listener = Listener.new
26:     #parser = REXML::Parsers::StreamParser.new(File.new(filename), listener)
27:     parser = StreamParser.new(filename_or_xml, listener)
28:     parser.parse
29:     listener.result
30:   end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.