Class: Thread

Inherits:
Object
  • Object
show all
Defined in:
lib/sapience/core_ext/thread.rb

Instance Method Summary collapse

Instance Method Details

#nameObject

Returns the name of the current thread Default:

String representation of this thread's object_id


8
9
10
# File 'lib/sapience/core_ext/thread.rb', line 8

def name
  @name ||= object_id.to_s
end

#name=(name) ⇒ Object

Set the name of this thread



13
14
15
# File 'lib/sapience/core_ext/thread.rb', line 13

def name=(name)
  @name = name.to_s
end