0.9.8.10
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
DispatchHandlerOperationDropTable.h
Go to the documentation of this file.
1 /* -*- c++ -*-
2  * Copyright (C) 2007-2015 Hypertable, Inc.
3  *
4  * This file is part of Hypertable.
5  *
6  * Hypertable is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU General Public License
8  * as published by the Free Software Foundation; version 3 of the
9  * License, or any later version.
10  *
11  * Hypertable is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
19  * 02110-1301, USA.
20  */
21 
22 #ifndef HYPERTABLE_DISPATCHHANDLEROPERATIONDROPTABLE_H
23 #define HYPERTABLE_DISPATCHHANDLEROPERATIONDROPTABLE_H
24 
25 #include "AsyncComm/CommAddress.h"
26 
28 
29 namespace Hypertable {
30 
32  public:
34  DispatchHandlerOperation(context), m_table(table) { }
35  virtual void start(const String &location) {
36  CommAddress addr;
37  addr.set_proxy(location);
38  m_rsclient.drop_table(addr, m_table, this);
39  }
40  private:
42  };
43  typedef std::shared_ptr<DispatchHandlerOperationDropTable> DispatchHandlerOperationDropTablePtr;
44 
45 }
46 
47 #endif // HYPERTABLE_DISPATCHHANDLEROPERATIONDROPTABLE_H
std::string String
A String is simply a typedef to std::string.
Definition: String.h:44
DispatchHandlerOperationDropTable(ContextPtr &context, const TableIdentifier &table)
Declarations for CommAddress.
std::shared_ptr< Context > ContextPtr
Smart pointer to Context.
Definition: Context.h:265
Wrapper for TableIdentifier providing member storage.
DispatchHandler class for managing async RangeServer requests.
Declarations for DispatchHandlerOperation.
void set_proxy(const String &str)
Sets address type to CommAddress::PROXY and proxy name to p.
Definition: CommAddress.h:76
RangeServer::Client m_rsclient
Range server client object
virtual void start(const String &location)
Method overridden in derived class for issuing requests.
Hypertable definitions
void drop_table(const CommAddress &addr, const TableIdentifier &table, DispatchHandler *handler)
Issues a "drop table" request asynchronously.
Definition: Client.cc:404
std::shared_ptr< DispatchHandlerOperationDropTable > DispatchHandlerOperationDropTablePtr
Address abstraction to hold either proxy name or IPv4:port address.
Definition: CommAddress.h:52