Module: Bmf::Dialog

Defined in:
lib/bmf-dialog.rb,
lib/bmf-dialog/parser.rb,
lib/bmf-dialog/version.rb,
lib/bmf-dialog/parser/line.rb,
lib/bmf-dialog/parser/dialog_parser.rb

Defined Under Namespace

Classes: DialogParser, Line, Parser

Constant Summary collapse

VERSION =
"0.0.1"

Class Method Summary collapse

Class Method Details

.parse(data_or_path) ⇒ Object



7
8
9
10
11
12
# File 'lib/bmf-dialog.rb', line 7

def parse(data_or_path)
  data_or_path = File.open(data_or_path, "r") if File.exists?(data_or_path)
  data_or_path = data_or_path.read if data_or_path.respond_to?(:read)

  Parser.new(data_or_path).parse.to_plist
end