def self.do_action(action, input, plogic, lang, toppings)
output = nil
case action
when 'compile'
output = self.compile(input, plogic, lang, toppings)
when 'convert'
output = self.convert(input, toppings)
when 'translate'
output = self.translate(input + plogic, lang, toppings)
when 'parse'
output = self.parse_stmt(input + plogic, toppings)
when 'expr', 'parse-expr'
output = self.parse_expr(input + plogic, toppings)
when 'scan'
output = self.scan(input + plogic, toppings)
when 'delete_directives'
attr_name = toppings[:attr_name] || 'kd'
output = self.delete_directives(input, attr_name)
when 'fetch'
output = self.fetch(input)
when 'analyze'
output = self.analyze(input, plogic, toppings)
end
return output
end