| | 1 | | namespace Morpho25.Settings |
| | 2 | | { |
| | 3 | | /// <summary> |
| | 4 | | /// Model timing settings. |
| | 5 | | /// </summary> |
| | 6 | | public class ModelTiming : Configuration |
| | 7 | | { |
| | 8 | | private uint _surfaceSteps; |
| | 9 | | private uint _flowSteps; |
| | 10 | | private uint _radiationSteps; |
| | 11 | | private uint _plantSteps; |
| | 12 | | private uint _sourcesSteps; |
| | 13 | | /// <summary> |
| | 14 | | /// Update Surface Data each ? sec. |
| | 15 | | /// </summary> |
| | 16 | | public uint SurfaceSteps |
| | 17 | | { |
| 6 | 18 | | get { return _surfaceSteps; } |
| | 19 | | set |
| 4 | 20 | | { |
| 4 | 21 | | _surfaceSteps = value; |
| 4 | 22 | | } |
| | 23 | | } |
| | 24 | | /// <summary> |
| | 25 | | /// Update Wind field each ? sec. |
| | 26 | | /// </summary> |
| | 27 | | public uint FlowSteps |
| | 28 | | { |
| 6 | 29 | | get { return _flowSteps; } |
| | 30 | | set |
| 2 | 31 | | { |
| 2 | 32 | | _flowSteps = value; |
| 2 | 33 | | } |
| | 34 | | } |
| | 35 | | /// <summary> |
| | 36 | | /// Update Radiation and Shadows each ? sec. |
| | 37 | | /// </summary> |
| | 38 | | public uint RadiationSteps |
| | 39 | | { |
| 3 | 40 | | get { return _radiationSteps; } |
| | 41 | | set |
| 2 | 42 | | { |
| 2 | 43 | | _radiationSteps = value; |
| 2 | 44 | | } |
| | 45 | | } |
| | 46 | | /// <summary> |
| | 47 | | /// Update Plant Data each ? sec. |
| | 48 | | /// </summary> |
| | 49 | | public uint PlantSteps |
| | 50 | | { |
| 3 | 51 | | get { return _plantSteps; } |
| | 52 | | set |
| 2 | 53 | | { |
| 2 | 54 | | _plantSteps = value; |
| 2 | 55 | | } |
| | 56 | | } |
| | 57 | | /// <summary> |
| | 58 | | /// Update Emmission Data each ? sec. |
| | 59 | | /// </summary> |
| | 60 | | public uint SourcesSteps |
| | 61 | | { |
| 3 | 62 | | get { return _sourcesSteps; } |
| | 63 | | set |
| 2 | 64 | | { |
| 2 | 65 | | _sourcesSteps = value; |
| 2 | 66 | | } |
| | 67 | | } |
| | 68 | | /// <summary> |
| | 69 | | /// Create model timing object. |
| | 70 | | /// </summary> |
| 2 | 71 | | public ModelTiming() |
| 2 | 72 | | { |
| 2 | 73 | | SurfaceSteps = 30; |
| 2 | 74 | | FlowSteps = 900; |
| 2 | 75 | | RadiationSteps = 600; |
| 2 | 76 | | PlantSteps = 600; |
| 2 | 77 | | SourcesSteps = 600; |
| 2 | 78 | | } |
| | 79 | |
|
| | 80 | | /// <summary> |
| | 81 | | /// Title of the XML section |
| | 82 | | /// </summary> |
| 1 | 83 | | public string Title => "ModelTiming"; |
| | 84 | |
|
| | 85 | | /// <summary> |
| | 86 | | /// Values of the XML section |
| | 87 | | /// </summary> |
| 1 | 88 | | public string[] Values => new[] { |
| 1 | 89 | | SurfaceSteps.ToString(), |
| 1 | 90 | | FlowSteps.ToString(), |
| 1 | 91 | | RadiationSteps.ToString(), |
| 1 | 92 | | PlantSteps.ToString(), |
| 1 | 93 | | SourcesSteps.ToString() |
| 1 | 94 | | }; |
| | 95 | |
|
| | 96 | | /// <summary> |
| | 97 | | /// Tags of the XML section |
| | 98 | | /// </summary> |
| 1 | 99 | | public string[] Tags => new[] { |
| 1 | 100 | | "surfaceSteps", |
| 1 | 101 | | "flowSteps", |
| 1 | 102 | | "radiationSteps", |
| 1 | 103 | | "plantSteps", |
| 1 | 104 | | "sourcesSteps" |
| 1 | 105 | | }; |
| | 106 | |
|
| | 107 | | /// <summary> |
| | 108 | | /// String representation of ModelTiming object. |
| | 109 | | /// </summary> |
| | 110 | | /// <returns>String representation.</returns> |
| 0 | 111 | | public override string ToString() => "Config::ModelTiming"; |
| | 112 | | } |
| | 113 | |
|
| | 114 | | } |