Remove unused number of threads option again

This commit is contained in:
Patrick Niklaus
2017-10-16 13:17:09 +00:00
committed by Michael Krasnyk
parent dc81c7b926
commit 456b198702
5 changed files with 8 additions and 21 deletions
-1
View File
@@ -88,7 +88,6 @@ struct EngineConfig final
int max_alternatives = 3; // set an arbitrary upper bound; can be adjusted by user
bool use_shared_memory = true;
Algorithm algorithm = Algorithm::CH;
int use_threads_number = 1;
std::string verbosity;
};
}
-8
View File
@@ -186,7 +186,6 @@ inline engine_config_ptr argumentsToEngineConfig(const Nan::FunctionCallbackInfo
params->Get(Nan::New("max_locations_map_matching").ToLocalChecked());
auto max_results_nearest = params->Get(Nan::New("max_results_nearest").ToLocalChecked());
auto max_alternatives = params->Get(Nan::New("max_alternatives").ToLocalChecked());
auto use_threads_number = params->Get(Nan::New("use_threads_number").ToLocalChecked());
if (!max_locations_trip->IsUndefined() && !max_locations_trip->IsNumber())
{
@@ -218,11 +217,6 @@ inline engine_config_ptr argumentsToEngineConfig(const Nan::FunctionCallbackInfo
Nan::ThrowError("max_alternatives must be an integral number");
return engine_config_ptr();
}
if (!use_threads_number->IsUndefined() && !use_threads_number->IsNumber())
{
Nan::ThrowError("use_threads_number must be an integral number");
return engine_config_ptr();
}
if (max_locations_trip->IsNumber())
engine_config->max_locations_trip = static_cast<int>(max_locations_trip->NumberValue());
@@ -239,8 +233,6 @@ inline engine_config_ptr argumentsToEngineConfig(const Nan::FunctionCallbackInfo
engine_config->max_results_nearest = static_cast<int>(max_results_nearest->NumberValue());
if (max_alternatives->IsNumber())
engine_config->max_alternatives = static_cast<int>(max_alternatives->NumberValue());
if (use_threads_number->IsNumber())
engine_config->use_threads_number = static_cast<int>(use_threads_number->NumberValue());
return engine_config;
}