Class: MonitoredHash
- Inherits:
-
Hash
- Object
- Hash
- MonitoredHash
- Includes:
- Observable
- Defined in:
- lib/repositories/monitored_hash.rb
Instance Method Summary collapse
- #[]=(key, value) ⇒ Object
- #clear ⇒ Object
- #delete(key, &block) ⇒ Object
- #merge!(hsh) ⇒ Object
- #nontainting_assign ⇒ Object
- #nontainting_clear ⇒ Object
- #nontainting_delete ⇒ Object
- #nontainting_merge! ⇒ Object
- #nontainting_reject! ⇒ Object
- #nontainting_replace ⇒ Object
- #nontainting_shift ⇒ Object
- #nontainting_store ⇒ Object
- #nontainting_update ⇒ Object
- #reject!(&block) ⇒ Object
- #replace(hsh) ⇒ Object
- #shift ⇒ Object
- #store(key, value) ⇒ Object
- #update(hsh) ⇒ Object
Instance Method Details
#[]=(key, value) ⇒ Object
7 8 9 10 11 |
# File 'lib/repositories/monitored_hash.rb', line 7 def []=(key, value) nontainting_assign(key, value) changed notify_observers(self) end |
#clear ⇒ Object
35 36 37 38 39 |
# File 'lib/repositories/monitored_hash.rb', line 35 def clear nontainting_clear changed notify_observers(self) end |
#delete(key, &block) ⇒ Object
14 15 16 17 18 |
# File 'lib/repositories/monitored_hash.rb', line 14 def delete(key, &block) nontainting_delete(key, &block) changed notify_observers(self) end |
#merge!(hsh) ⇒ Object
42 43 44 45 46 |
# File 'lib/repositories/monitored_hash.rb', line 42 def merge!(hsh) nontainting_merge!(hsh) changed notify_observers(self) end |
#nontainting_assign ⇒ Object
6 |
# File 'lib/repositories/monitored_hash.rb', line 6 alias :nontainting_assign :[]= |
#nontainting_clear ⇒ Object
34 |
# File 'lib/repositories/monitored_hash.rb', line 34 alias :nontainting_clear :clear |
#nontainting_delete ⇒ Object
13 |
# File 'lib/repositories/monitored_hash.rb', line 13 alias :nontainting_delete :delete |
#nontainting_merge! ⇒ Object
41 |
# File 'lib/repositories/monitored_hash.rb', line 41 alias :nontainting_merge! :merge! |
#nontainting_reject! ⇒ Object
27 |
# File 'lib/repositories/monitored_hash.rb', line 27 alias :nontainting_reject! :reject! |
#nontainting_replace ⇒ Object
48 |
# File 'lib/repositories/monitored_hash.rb', line 48 alias :nontainting_replace :replace |
#nontainting_shift ⇒ Object
20 |
# File 'lib/repositories/monitored_hash.rb', line 20 alias :nontainting_shift :shift |
#nontainting_store ⇒ Object
55 |
# File 'lib/repositories/monitored_hash.rb', line 55 alias :nontainting_store :store |
#nontainting_update ⇒ Object
62 |
# File 'lib/repositories/monitored_hash.rb', line 62 alias :nontainting_update :update |
#reject!(&block) ⇒ Object
28 29 30 31 32 |
# File 'lib/repositories/monitored_hash.rb', line 28 def reject!(&block) nontainting_reject!(&block) changed notify_observers(self) end |
#replace(hsh) ⇒ Object
49 50 51 52 53 |
# File 'lib/repositories/monitored_hash.rb', line 49 def replace(hsh) nontainting_replace(hsh) changed notify_observers(self) end |
#shift ⇒ Object
21 22 23 24 25 |
# File 'lib/repositories/monitored_hash.rb', line 21 def shift nontainting_shift changed notify_observers(self) end |
#store(key, value) ⇒ Object
56 57 58 59 60 |
# File 'lib/repositories/monitored_hash.rb', line 56 def store(key, value) nontainting_store(key, value) changed notify_observers(self) end |
#update(hsh) ⇒ Object
63 64 65 66 67 |
# File 'lib/repositories/monitored_hash.rb', line 63 def update(hsh) nontainting_update(hsh) changed notify_observers(self) end |