Class: RbEAI::GetLogic
- Inherits:
-
Object
- Object
- RbEAI::GetLogic
- Defined in:
- lib/rbeai/GetLogic.rb
Instance Method Summary collapse
- #getFiles ⇒ Object
-
#initialize(xmlDoc, task) ⇒ GetLogic
constructor
A new instance of GetLogic.
Constructor Details
#initialize(xmlDoc, task) ⇒ GetLogic
Returns a new instance of GetLogic.
14 15 16 17 18 19 20 21 22 23 |
# File 'lib/rbeai/GetLogic.rb', line 14 def initialize(xmlDoc, task) @task = task protNode = XPath.first(xmlDoc, "./protocol") protocol = protNode.attributes["def"] @logic = case protocol when "file" then GetFileLogic.new(protNode, task) when "ftp" then GetFtpLogic.new(protNode, task) when "email" then GetEmailLogic.new(protNode, task) end end |
Instance Method Details
#getFiles ⇒ Object
25 26 27 |
# File 'lib/rbeai/GetLogic.rb', line 25 def getFiles() return @logic.getFiles() end |