Skip to content
Snippets Groups Projects
Commit 831e1db2 authored by Marco Matthies's avatar Marco Matthies
Browse files

Remove unneeded commented-out code

parent 02ca2723
No related branches found
No related tags found
No related merge requests found
......@@ -70,44 +70,3 @@ function initfields!(model::SimulationModel)
@info "Initialised $(length(model.farmplots)) farm plots."
end
# # TODO: this function should be moved to the individual crop models,
# # and overloaded on the type of cropstate (see notes above)
# """
# setsoiltype!(farmplot, soiltype, model)
# """
# function setsoiltype!(farmplot::FarmPlot, soiltype::SoilType, model::SimulationModel)
# farmplot.soiltype = soiltype
# if @param(crop.cropmodel) == "aquacrop"
# farmplot.cropstate.soiltype = soiltype
# else
# # do nothing for other cropmodels
# end
# end
# # TODO: move this function to individual crop model files
# """
# makecropstate(model, soiltype)
#
# An internal utility function to initialise one instance of the configured crop growth model.
# """
# function makecropstate(model::SimulationModel, soiltype::SoilType)
# if @param(crop.cropmodel) == "almass"
# phase = (month(model.date) < 3 ? ALMaSS.janfirst : ALMaSS.marchfirst)
# cs = ALMaSS.CropState(
# croptype = model.crops["natural grass"],
# phase = phase,
# )
# elseif @param(crop.cropmodel) == "simple"
# cs = SimpleCrop.CropState(
# model.crops["natural grass"],
# 0.0m
# )
# elseif @param(crop.cropmodel) == "aquacrop"
# croptype = model.crops["natural grass"]
# cs = AquaCropWrapper.CropState(croptype, soiltype, model)
# else
# Base.error("Unhandled crop model '$(@param(crop.cropmodel))' in makecropstate().")
# end
# return cs
# end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment