Class: Droonga::Plugins::Groonga::TableRemove::Command
- Inherits:
-
GenericCommand
- Object
- GenericCommand
- Droonga::Plugins::Groonga::TableRemove::Command
- Defined in:
- lib/droonga/plugins/groonga/table_remove.rb
Instance Method Summary collapse
Methods inherited from GenericCommand
Constructor Details
This class inherits a constructor from Droonga::Plugins::Groonga::GenericCommand
Instance Method Details
#process_request(request) ⇒ Object
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 |
# File 'lib/droonga/plugins/groonga/table_remove.rb', line 26 def process_request(request) command_class = ::Groonga::Command.find("table_remove") @command = command_class.new("table_remove", request) name = @command["name"] if name.nil? or @context[name].nil? raise CommandError.new(:status => Status::INVALID_ARGUMENT, :message => "table not found", :result => false) end ::Groonga::Schema.define(:context => @context) do |schema| schema.remove_table(name) end true end |