module Beret
Constants
- VERSION
Public Class Methods
new(json)
click to toggle source
# File lib/beret.rb, line 10 def self.new(json) array = json.kind_of?(Array) ? json : JSON.parse(json) Beret::BlockSet.new(array) rescue JSON::ParserError raise "String provided to Beret.new() was not valid JSON." end