module Labelizer

Constants

VERSION

Public Class Methods

included(base) click to toggle source
# File lib/labelizer.rb, line 8
def self.included(base)
  base.send :extend, ClassMethods
end

Public Instance Methods

labelized() click to toggle source
# File lib/labelizer.rb, line 12
def labelized
  @labelized ||= Container.new(self.class.labelized.instance_variable_get(:@keys)){|h,attr|
    h[attr] = self.class.labelized[attr][__send__(attr)]
  }
end