Sha256: 3d7462a1c57ec9afb7525f2e505039eb13cf8d16155487cc4c33645538e90f5c

Contents?: true

Size: 439 Bytes

Versions: 5

Compression:

Stored size: 439 Bytes

Contents

$LOAD_PATH.unshift File.expand_path(File.join(File.dirname(__FILE__), "/../lib"))
require 'hash_model'

  deep_hash =  { 
    :parameter__type=>String,
    :switch__deep1__deep3 => "deepTwo",
    :parameter__type__ruby=>true,
    :parameter => "glorp",
    :parameter__require=>true,
    :switch__deep2 => "deepTwo",
    :description=>"Xish stuff",
    :switch => "--xtend",
  }
  unflat = HashModel.unflatten(deep_hash) 
  
  puts unflat

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
hashmodel-0.4.0.beta1 _brainstorm/unflat.rb
hashmodel-0.3.1 _brainstorm/unflat.rb
hashmodel-0.3.0 _brainstorm/unflat.rb
hashmodel-0.3.0.beta2 _brainstorm/unflat.rb
hashmodel-0.3.0.beta1 _brainstorm/unflat.rb