MCPcopy Create free account
hub / github.com/catboost/catboost / GetContainerOption

Function GetContainerOption

library/cpp/text_processing/tokenizer/options.cpp:42–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

40
41template <typename TContainerType>
42static void GetContainerOption(const NJson::TJsonValue& optionsJson, const TString& name, TContainerType* result) {
43 if (optionsJson.Has(name)) {
44 result->clear();
45 for (const auto& element : optionsJson[name].GetArray()) {
46 result->insert(result->end(), FromString<typename TContainerType::value_type>(element.GetString()));
47 }
48 }
49}
50
51void NTextProcessing::NTokenizer::TokenizerOptionsToJson(const TTokenizerOptions& options, NJson::TJsonValue* optionsJson) {
52 SetOption(options.Lowercasing, LOWERCASING_OPTION_NAME, optionsJson);

Callers 1

Calls 6

HasMethod · 0.45
clearMethod · 0.45
GetArrayMethod · 0.45
insertMethod · 0.45
endMethod · 0.45
GetStringMethod · 0.45

Tested by

no test coverage detected