Class: ReentrantMutex

### Home Classes Methods

### In Files

- lib/logging/utils.rb

### Parent

Mutex

### Methods

- ::new
- #original_synchronize
- #synchronize

### Files

- History.txt

### Class/Module Index

Quicksearch

- Logging
- Logging::Appender
- Logging::Appenders
- Logging::Appenders::Buffering
- Logging::Appenders::File
- Logging::Appenders::IO
- Logging::Appenders::RollingFile
- Logging::Appenders::RollingFile::Roller
- Logging::Appenders::Stderr
- Logging::Appenders::Stdout
- Logging::Appenders::StringIo
- Logging::Appenders::Syslog
- Logging::ColorScheme
- Logging::Filter
- Logging::Filters
- Logging::Filters::Level
- Logging::Layout
- Logging::Layouts
- Logging::Layouts::Basic
- Logging::Layouts::Parseable
- Logging::Layouts::Pattern
- Logging::Logger
- Logging::MappedDiagnosticContext
- Logging::NestedDiagnosticContext
- Logging::Proxy
- Logging::RailsCompat
- Logging::Repository
- Logging::Repository::Singleton
- Logging::RootLogger
- RSpec
- RSpec::Core
- RSpec::Core::Configuration
- RSpec::LoggingHelper
- RSpec::LoggingHelper
- Spec
- Spec::Runner
- Spec::Runner::Configuration
- Object
- Object::LoggingHelper
- File
- FileUtils
- Module
- ReentrantMutex
- String

No matching classes.

# ReentrantMutex

### Public Class Methods

new() click to toggle source

    # File lib/logging/utils.rb, line 148
    def initialize
      super
      @locker = nil
    end

### Public Instance Methods

original_synchronize() click to toggle source
Alias for: synchronize
synchronize() click to toggle source

    # File lib/logging/utils.rb, line 155
    def synchronize
      if @locker == Thread.current
        yield
      else
        original_synchronize {
          begin
            @locker = Thread.current
            yield
          ensure
            @locker = nil
          end
        }
      end
    end

Also aliased as: original_synchronize

[Validate]

Generated with the Darkfish Rdoc Generator 2.