基本可用。
This commit is contained in:
32
bf.xlnt.h
Normal file
32
bf.xlnt.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef BF_XLNT_H
|
||||
#define BF_XLNT_H
|
||||
|
||||
#include <unordered_map>
|
||||
#include <xlnt/xlnt.hpp>
|
||||
|
||||
#include "bf.config.h"
|
||||
#include "bf.request.h"
|
||||
#include "bf.util.h"
|
||||
|
||||
class BF_Xlnt
|
||||
{
|
||||
public:
|
||||
BF_Xlnt() = default;
|
||||
|
||||
public:
|
||||
void Reset();
|
||||
void Set(BF_Interface* request, std::shared_ptr<BF_Config> bfConfig);
|
||||
bool parseXlsx(const std::string& file, std::vector<XlsxTask>& tasks, const std::string& sheetName);
|
||||
|
||||
private:
|
||||
bool Fanyi(int i, int j, xlnt::worksheet& ws, const XlsxTask& task, std::string& out);
|
||||
bool GetCell(int i, int j, xlnt::worksheet& ws, xlnt::cell_reference& out);
|
||||
|
||||
private:
|
||||
BF_Interface* request_{};
|
||||
std::shared_ptr<BF_Config> bfConfig_{};
|
||||
|
||||
std::unordered_map<std::string, std::string> fanyiHistory_{};
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user