[go: up one dir, main page]

Menu

[r39]: / client / speclient.h  Maximize  Restore  History

Download this file

75 lines (54 with data), 1.1 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
#ifndef __SECTOR_H__
#define __SECTOR_H__
#include "client.h"
#include <string>
#include <pthread.h>
#include <udt.h>
using namespace std;
namespace cb
{
class Process
{
friend class Client;
public:
Process();
~Process();
int open(vector<string> stream, string op, const char* param = NULL, const int& size = 0);
int close();
int run();
int read(char*& data, int& size, string& file, int64_t& offset, int& rows, const bool& inorder);
private:
static void* run(void*);
private:
string m_strOperator;
string m_strParam;
vector<string> m_vstrStream;
struct DS
{
string m_strDataFile;
int64_t m_llOffset;
int64_t m_llSize;
int m_iSPEID;
char* m_pResult;
int m_iResSize;
};
vector<DS> m_vDS;
struct SPE
{
uint32_t m_uiID;
Node m_Loc;
DS* m_pDS;
int m_iStatus;
int m_iProgress;
UDTSOCKET m_DataSock;
};
vector<SPE> m_vSPE;
int m_iProgress;
pthread_mutex_t m_ResLock;
pthread_cond_t m_ResCond;
int m_iMinUnitSize;
int m_iMaxUnitSize;
CGMP m_GMP;
};
}; // namespace cb
#endif