I have a file that contains a List of what “Algo” I should run
Then Julia should read it and Create an instance of the correct “Algo” object:
abstract type OptimizationAlgo end
struct Linear <: OptimizationAlgo end
struct Quad <: OptimizationAlgo end
struct ThirdOrder <: OptimizationAlgo end
algo_str = readline() # Let's say I type in "Linear"
# Convert algo_str to the correct algo struct
# How to do it??
i can’t think of another solution of that other that a long function with a lot of ifs, maybe that is the correct approach, because the algorithm is not known a priori (before reading the file)