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


6
7
8
# File 'lib/sapience/core_ext/thread.rb', line 6

def name
  @name ||= object_id.to_s
end

#name=(name) ⇒ Object

Set the name of this thread



11
12
13
# File 'lib/sapience/core_ext/thread.rb', line 11

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