82 #ifndef END_POINT_BINARY_H
83 #define END_POINT_BINARY_H
92 #define BINARY_SET_SIZE 0
93 #define BINARY_ENABLE_TRANSPOSE_ON_READ 1
94 #define BINARY_ENABLE_TRANSPOSE_ON_WRITE 2
95 #define BINARY_DISABLE_TRANSPOSE_ON_READ 3
96 #define BINARY_DISABLE_TRANSPOSE_ON_WRITE 4
98 #define BINARY_ENABLE_TRAN_READ BINARY_ENABLE_TRANSPOSE_ON_READ
99 #define BINARY_ENABLE_TRAN_WRITE BINARY_ENABLE_TRANSPOSE_ON_WRITE
100 #define BINARY_DISABLE_TRAN_READ BINARY_DISABLE_TRANSPOSE_ON_READ
101 #define BINARY_DISABLE_TRAN_WRITE BINARY_DISABLE_TRANSPOSE_ON_WRITE
119 std::string model_str =
"r";
123 long int seek_offset = 0;
125 bool tranpose_on_read_flag =
false;
126 bool tranpose_on_write_flag =
false;
159 model_str = model_str_p;
201 int Read(std::vector<unsigned long long> start, std::vector<unsigned long long> end,
void *data)
override;
211 int Write(std::vector<unsigned long long> start, std::vector<unsigned long long> end,
void *data)
override;
218 int Close()
override;
240 int Control(
int opt_code, std::vector<std::string> ¶meter_v)
override;
Definition: ft_endpoint_binary.h:105
int Close() override
close the end-point
Definition: ft_endpoint_binary.cpp:255
int ExtractMeta() override
extracts metadata, possbile endpoint_ranks/endpoint_dim_size/data_element_type
Definition: ft_endpoint_binary.cpp:84
EndpointBinary()
Construct a new Endpoint in Binary Nothing to do there, can be used as sub-endpoint of directory.
Definition: ft_endpoint_binary.h:146
int Open() override
open the endpoint
Definition: ft_endpoint_binary.cpp:103
void Map2MyType() override
call the finalize to close everything (like call Destractor)
Definition: ft_endpoint_binary.cpp:270
void SetMode(std::string model_str_p)
Definition: ft_endpoint_binary.h:157
int Create() override
create the endpoint
Definition: ft_endpoint_binary.cpp:89
int MapOpStr2Int(std::string op_cmd_str) override
map a op_cmd_str to int as input of SpecialOperator
Definition: ft_endpoint_binary.cpp:437
virtual void UpdateSeekOffset()
update the seek_offset
Definition: ft_endpoint_binary.cpp:333
std::string MapOpInt2Str(int op_int) override
map op_int to string
Definition: ft_endpoint_binary.cpp:463
int Write(std::vector< unsigned long long > start, std::vector< unsigned long long > end, void *data) override
write the data to the end-point
Definition: ft_endpoint_binary.cpp:222
void SetSeekOffset(long int seek_offset_p)
Set the Seek Offset.
Definition: ft_endpoint_binary.cpp:426
virtual ~EndpointBinary()
Definition: ft_endpoint_binary.h:152
std::string GetMode()
Definition: ft_endpoint_binary.h:162
EndpointBinary(std::string endpoint_info_p)
Construct a new EndpointBinary object.
Definition: ft_endpoint_binary.h:135
FILE * GetFP()
Get file point.
Definition: ft_endpoint_binary.cpp:421
int ParseEndpointInfo() override
parse endpoint_info to my own info In binary, it map endpoint_info to filename,
Definition: ft_endpoint_binary.cpp:317
void DisableTranposeOnWrite()
DisableTranposeOnWrite.
Definition: ft_endpoint_binary.cpp:502
int PrintInfo() override
print information about the endpoint
Definition: ft_endpoint_binary.cpp:264
void EnableTranposeOnWrite()
EnableTranposeOnWrite.
Definition: ft_endpoint_binary.cpp:484
void EnableTranposeOnRead()
EnableTranposeOnRead.
Definition: ft_endpoint_binary.cpp:475
int Control(int opt_code, std::vector< std::string > ¶meter_v) override
call a special operator on binary endpoint such as OP_SET_BINARY_SIZE
Definition: ft_endpoint_binary.cpp:378
int Read(std::vector< unsigned long long > start, std::vector< unsigned long long > end, void *data) override
read the data from end-point
Definition: ft_endpoint_binary.cpp:137
void DisableTranposeOnRead()
DisableTranposeOnRead.
Definition: ft_endpoint_binary.cpp:493
Define the class for the Endpoint used by ArrayUDF to store the data. It contains basic infomation fo...
Definition: ft_endpoint.h:106
void SetEndpointType(AuEndpointType endpoint_type_p)
Set the Endpoint Type object.
Definition: ft_endpoint.cpp:355
void SetOpenFlag(bool open_flag_p)
Definition: ft_endpoint.cpp:156
std::string endpoint_info
Definition: ft_endpoint.h:109
@ EP_BINARY
Definition: ft_type.h:99