Class: WebFlow::Plugin
- Inherits:
-
Object
- Object
- WebFlow::Plugin
- Defined in:
- lib/webflow/plugin.rb
Overview
This is a skeleton class to create plugins to the WebFlow framework. Any plugin MUST me a subclass of this superclass.
Plugins are still under development so they are not activated yet.
Direct Known Subclasses
Class Method Summary collapse
-
.call(system_event) ⇒ Object
Method called by a controller when a system event for which this plugin is registered is reached.
Class Method Details
.call(system_event) ⇒ Object
Method called by a controller when a system event for which this plugin is registered is reached.
33 34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/webflow/plugin.rb', line 33 def self::call(system_event) # Execute the plugin return_value = self.notify # Make sure we got a system event back raise(WebFlowError.new, "One of your plugin didn't return a system event, as required. The culprit is : " + self.inspect ) unless return_value.kind_of? WebFlow::SystemEvent # Act accordingly return return_value end |