class YleTf::Plugin::ActionHook
Attributes
actions[R]
Public Class Methods
new(actions)
click to toggle source
# File lib/yle_tf/plugin/action_hook.rb, line 8 def initialize(actions) @actions = actions end
Public Instance Methods
after(existing, new, *args, &block)
click to toggle source
# File lib/yle_tf/plugin/action_hook.rb, line 16 def after(existing, new, *args, &block) actions.insert_after(existing, new, *args, &block) if actions.include?(existing) end
before(existing, new, *args, &block)
click to toggle source
# File lib/yle_tf/plugin/action_hook.rb, line 12 def before(existing, new, *args, &block) actions.insert_before(existing, new, *args, &block) if actions.include?(existing) end