Module: AgentDispatcher::AgentDispatcherClassMethods
- Defined in:
- lib/agentdispatcher.rb
Instance Method Summary collapse
-
#__injections__ ⇒ Object
inherit by merging.
-
#AllowedCommands ⇒ Object
inherit by replacing.
-
#DefaultCfg ⇒ Object
inherit by merging.
- #Dispatch(*argv) ⇒ Object
- #DispatchString(aString) ⇒ Object
- #downMethod(aMethod, aPriority = 0) ⇒ Object
- #upMethod(aMethod, aPriority = 0) ⇒ Object
Instance Method Details
#__injections__ ⇒ Object
inherit by merging
171 172 173 174 175 |
# File 'lib/agentdispatcher.rb', line 171 def __injections__ injs = @__injections__ || {} injs = (superclass.__injections__.merge injs) if self.superclass.respond_to? :__injections__ injs end |
#AllowedCommands ⇒ Object
inherit by replacing
185 186 187 |
# File 'lib/agentdispatcher.rb', line 185 def AllowedCommands @AllowedCommands || (superclass.AllowedCommands() if self.superclass.respond_to? :AllowedCommands) || [] end |
#DefaultCfg ⇒ Object
inherit by merging
178 179 180 181 182 |
# File 'lib/agentdispatcher.rb', line 178 def DefaultCfg hash = @DefaultCfg || {} hash = (superclass.DefaultCfg.merge hash) if self.superclass.respond_to? :DefaultCfg hash end |
#Dispatch(*argv) ⇒ Object
197 198 199 200 201 |
# File 'lib/agentdispatcher.rb', line 197 def Dispatch *argv instance = self.new instance.dispatch *argv instance end |
#DispatchString(aString) ⇒ Object
203 204 205 |
# File 'lib/agentdispatcher.rb', line 203 def DispatchString aString Dispatch *aString.split end |
#downMethod(aMethod, aPriority = 0) ⇒ Object
193 194 195 |
# File 'lib/agentdispatcher.rb', line 193 def downMethod aMethod, aPriority = 0 @__injections__[aMethod.to_sym]=[:preExit, aPriority] end |
#upMethod(aMethod, aPriority = 0) ⇒ Object
189 190 191 192 |
# File 'lib/agentdispatcher.rb', line 189 def upMethod aMethod, aPriority = 0 @__injections__ = {} unless @__injections__ @__injections__[aMethod.to_sym]=[:postInit, aPriority] end |