RubyGems.org

A version of Ruby's Struct class that creates classes whose instances are immutable. It works just as Struct, but there are no setters, and you can't use []=. As a bonus feature the constructor of classes inheriting from ImmutableStruct can take named parameters in the form of a hash.

installgem install immutable_struct
Authors

Theo Hultberg, Ben Cates

3,407 total downloads 455 for this version
Owners

8c21306523b16ba5dd35c3549bf90994

Gemfile
gem "immutable_struct", "~> 1.1.0"
Versions
  1. 1.1.0 December 20, 2012
  2. 1.0.2 September 25, 2010
  3. 1.0.0 March 12, 2010
Development Dependencies
  1. rspec >= 0
  2. yard >= 0