Class: HookR::NullHook

Inherits:
Object
  • Object
show all
Defined in:
lib/hookr.rb

Overview

A null object class for terminating Hook inheritance chains

Instance Method Summary collapse

Instance Method Details

#each_callback(&block) ⇒ Object



432
433
434
# File 'lib/hookr.rb', line 432

def each_callback(&block)
  # NOOP
end

#each_callback_reverse(&block) ⇒ Object



436
437
438
# File 'lib/hookr.rb', line 436

def each_callback_reverse(&block)
  # NOOP
end

#execute_callbacks(event) ⇒ Object



440
441
442
# File 'lib/hookr.rb', line 440

def execute_callbacks(event)
  # NOOP
end

#root?Boolean

Returns:

  • (Boolean)


452
453
454
# File 'lib/hookr.rb', line 452

def root?
  true
end

#terminal?Boolean

Returns:

  • (Boolean)


448
449
450
# File 'lib/hookr.rb', line 448

def terminal?
  true
end

#total_callbacksObject



444
445
446
# File 'lib/hookr.rb', line 444

def total_callbacks
  0
end