class Prawn::ThreadLocalCache
@private
Public Class Methods
new()
click to toggle source
# File lib/prawn/utilities.rb, line 36 def initialize @cache_id = "cache_#{self.object_id}".to_sym end
Public Instance Methods
[](key)
click to toggle source
# File lib/prawn/utilities.rb, line 39 def [](key) (Thread.current[@cache_id] ||= {})[key] end
[]=(key,value)
click to toggle source
# File lib/prawn/utilities.rb, line 42 def []=(key,value) (Thread.current[@cache_id] ||= {})[key] = value end