Auto update
This commit is contained in:
parent
dd7e9baae5
commit
35af30c31f
5669 changed files with 255689 additions and 292972 deletions
|
|
@ -34,8 +34,15 @@ public:
|
|||
ConverterPtr NewFromString(const std::string& json,
|
||||
const std::string& configDirectory);
|
||||
|
||||
ConverterPtr NewFromString(const std::string& json,
|
||||
const std::vector<std::string>& paths);
|
||||
|
||||
ConverterPtr NewFromFile(const std::string& fileName);
|
||||
|
||||
ConverterPtr NewFromFile(const std::string& fileName,
|
||||
const std::vector<std::string>& paths,
|
||||
const char* argv0);
|
||||
|
||||
private:
|
||||
void* internal;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -62,6 +62,8 @@ public:
|
|||
return entries.end();
|
||||
}
|
||||
|
||||
static LexiconPtr ParseLexiconFromFile(FILE* fp);
|
||||
|
||||
private:
|
||||
std::vector<std::unique_ptr<DictEntry>> entries;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ public:
|
|||
Segments() {}
|
||||
|
||||
Segments(std::initializer_list<const char*> initList) {
|
||||
for (const std::string& item : initList) {
|
||||
for (const char* item : initList) {
|
||||
AddSegment(item);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
#include "Export.hpp"
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#ifndef __OPENCC_SIMPLECONVERTER_HPP_
|
||||
#define __OPENCC_SIMPLECONVERTER_HPP_
|
||||
|
|
@ -29,6 +30,7 @@
|
|||
*/
|
||||
|
||||
namespace opencc {
|
||||
|
||||
/**
|
||||
* A high level converter
|
||||
* This interface does not require C++11 to compile.
|
||||
|
|
@ -40,7 +42,25 @@ public:
|
|||
* Constructor of SimpleConverter
|
||||
* @param configFileName File name of configuration.
|
||||
*/
|
||||
SimpleConverter(const std::string& configFileName);
|
||||
explicit SimpleConverter(const std::string& configFileName);
|
||||
|
||||
/**
|
||||
* Constructor of SimpleConverter
|
||||
* @param configFileName File name of configuration.
|
||||
* @param paths Additional paths to locate configuration and dictionary files.
|
||||
*/
|
||||
SimpleConverter(const std::string& configFileName,
|
||||
const std::vector<std::string>& paths);
|
||||
|
||||
/**
|
||||
* Constructor of SimpleConverter
|
||||
* @param configFileName File name of configuration.
|
||||
* @param paths Additional paths to locate configuration and dictionary files.
|
||||
* @param argv0 Path of the executable (argv[0]), in addition to additional
|
||||
* paths.
|
||||
*/
|
||||
SimpleConverter(const std::string& configFileName,
|
||||
const std::vector<std::string>& paths, const char* argv0);
|
||||
|
||||
~SimpleConverter();
|
||||
|
||||
|
|
|
|||
|
|
@ -19,9 +19,10 @@
|
|||
#pragma once
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#ifndef NOMINMAX
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
#include <Windows.h>
|
||||
#undef NOMINMAX
|
||||
#endif // _MSC_VER
|
||||
|
||||
#include <cstring>
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@
|
|||
# The variable CVF_VERSION must be set before calling configure_file().
|
||||
|
||||
|
||||
set(PACKAGE_VERSION "1.1.7")
|
||||
set(PACKAGE_VERSION "1.1.9")
|
||||
|
||||
if(PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
||||
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
||||
else()
|
||||
|
||||
if("1.1.7" MATCHES "^([0-9]+)\\.")
|
||||
if("1.1.9" MATCHES "^([0-9]+)\\.")
|
||||
set(CVF_VERSION_MAJOR "${CMAKE_MATCH_1}")
|
||||
if(NOT CVF_VERSION_MAJOR VERSION_EQUAL 0)
|
||||
string(REGEX REPLACE "^0+" "" CVF_VERSION_MAJOR "${CVF_VERSION_MAJOR}")
|
||||
endif()
|
||||
else()
|
||||
set(CVF_VERSION_MAJOR "1.1.7")
|
||||
set(CVF_VERSION_MAJOR "1.1.9")
|
||||
endif()
|
||||
|
||||
if(PACKAGE_FIND_VERSION_RANGE)
|
||||
|
|
|
|||
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue