0.9.8.10
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
LoadDataSourceFileDfs.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_LOAD_DATA_SOURCE_FILE_DFS_H
23 #define HYPERTABLE_LOAD_DATA_SOURCE_FILE_DFS_H
24 
25 #include <fstream>
26 #include <iostream>
27 #include <string>
28 #include <vector>
29 
30 #include <boost/iostreams/filtering_stream.hpp>
31 
32 #include "Common/ByteString.h"
33 #include "Common/DynamicBuffer.h"
34 #include "Common/String.h"
35 
36 #include "DataSource.h"
38 #include "LoadDataSource.h"
40 #include "FsBroker/Lib/Client.h"
41 
42 namespace Hypertable {
43 
45 
46  public:
47  LoadDataSourceFileDfs(FsBroker::Lib::ClientPtr &client, const std::string &fname,
48  const std::string &header_fname,
49  int row_uniquify_chars = 0, int load_flags = 0);
50 
52 
53  uint64_t incr_consumed();
54 
55  protected:
56  void init_src();
58  std::string m_fname;
59  std::string m_header_fname;
60  unsigned long m_cur_offset;
61  };
62 
63 } // namespace Hypertable
64 
65 #endif // HYPERTABLE_LOADDATASOURCEFILELOCAL_H
A dynamic, resizable memory buffer.
std::shared_ptr< Client > ClientPtr
Smart pointer to Client.
Definition: Client.h:233
LoadDataSourceFileDfs(FsBroker::Lib::ClientPtr &client, const std::string &fname, const std::string &header_fname, int row_uniquify_chars=0, int load_flags=0)
Hypertable definitions
FsBroker::Lib::FileSource * m_source
A String class based on std::string.
A serializable ByteString.
Declarations for Client.