Module: Windoo::Mixins::Immutable

Included in:
BaseClasses::Criterion
Defined in:
lib/windoo/mixins/immutable.rb

Overview

by default, instances of JSONObject subclasses are mutable as a whole, even if some of their attributes are not.

To make them immutable, they should extend this module

Windoo::Mixins::Immutable,

which overrides the mutable? method

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.extended(extender) ⇒ Object



21
22
23
# File 'lib/windoo/mixins/immutable.rb', line 21

def self.extended(extender)
  Windoo.verbose_extend extender, self
end

Instance Method Details

#mutable?Boolean

this class is immutable

Returns:

  • (Boolean)


26
27
28
# File 'lib/windoo/mixins/immutable.rb', line 26

def mutable?
  false
end