end end Opal.Foo.$new().$bar(); // => "sample class" var myHash = Opal.hash({a: 1, b: 2}); // output of $inspect: {"a"=>1, "b"=>2} myHash.$store('a', 10); // output of $inspect: {"a"=>10, "b"=>2} myHash.$fetch('b',''); // 2 myHash.$fetch('z',''); // "" myHash.$update(Opal.hash({b: 20, c: 30})); // output of $inspect: {"a"=>10, "b"=>20, "c"=>30} myHash.$to_n(); // provided by the Native module // output: {"a": 10, "b": 20, "c": 30} aka a standard Javascript object