Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class ToolParser
- def to_json
- self.to_json
- end
- def to_hash # or attributes
- self.to_hash
- end
- def execute(xml)
- raise NotImplementedError # do the hard work here
- end
- end
- class NessusParser < ToolParser
- def execute(xml)
- # do the hard work here and few other places :)
- end
- end
- class NmapParser < ToolParser
- def execute(xml)
- # do the hard work here and few other places :)
- end
- end
Add Comment
Please, Sign In to add comment