Skip to content

Commit

Permalink
tmp
Browse files Browse the repository at this point in the history
  • Loading branch information
Tilman Reinhardt committed Oct 9, 2023
1 parent f24600c commit 1f8fe70
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 12 deletions.
32 changes: 22 additions & 10 deletions GsaGH/Parameters/5_Results/GsaAnalysisCaseResult.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public class GsAnalysisCaseResult : IGsaResult {



internal Dictionary<int, GsaResultsValues> NodeDisplacementValues { get; set; } = new Dictionary<int, GsaResultsValues>();
internal Dictionary<int, GsaResultQuantity> NodeDisplacementValues { get; set; } = new Dictionary<int, GsaResultQuantity>();



Expand All @@ -60,8 +60,6 @@ public class GsAnalysisCaseResult : IGsaResult {

public CaseType Type { get; } = CaseType.AnalysisCase;

CaseType IGsaResult.Type => throw new NotImplementedException();

public GsAnalysisCaseResult() { }

internal GsAnalysisCaseResult(GsaModel model, AnalysisCaseResult result, int caseId) {
Expand All @@ -75,21 +73,35 @@ public GsaResultsValues GetNodeDisplacementValues(string nodelist, LengthUnit le
if (nodelist.ToLower() == "all" || nodelist == string.Empty) {
nodelist = "All";
}
if (!NodeDisplacementValues.ContainsKey(nodelist)) {
if (!ACaseNodeResults.ContainsKey(nodelist)) {
ACaseNodeResults.Add(nodelist, AnalysisCaseResult.NodeResults(nodelist));
}

NodeDisplacementValues.Add(nodelist,
ResultHelper.GetNodeResultValues(ACaseNodeResults[nodelist], lengthUnit));
if (!NodeDisplacementValues.ContainsKey(nodelist)) {
if (!ACaseNodeResults.ContainsKey(nodelist)) {
ACaseNodeResults.Add(nodelist, AnalysisCaseResult.NodeResults(nodelist));
}

NodeDisplacementValues.Add(nodelist,
ResultHelper.GetNodeResultValues(ACaseNodeResults[nodelist], lengthUnit));



}

return NodeDisplacementValues[nodelist];
}

protected ReadOnlyDictionary<int, ReadOnlyCollection<NodeResult>> GetAnalysisCaseNodeResults(string nodelist) {


ReadOnlyDictionary<int, NodeResult> values = AnalysisCaseResult.NodeResults(nodelist);


var result = new ReadOnlyDictionary<int, ReadOnlyCollection<NodeResult>>(values);


}

protected ReadOnlyDictionary<int, ReadOnlyCollection<NodeResult>> GetCombinationCaseNodeResults(string nodelist) {

}

public GsAnalysisCaseResult Duplicate() {
return this;
Expand Down
5 changes: 3 additions & 2 deletions GsaGH/Parameters/5_Results/IGsaResult.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
using OasysUnits.Units;
using System.Collections.Concurrent;
using OasysUnits.Units;

namespace GsaGH.Parameters {
public interface IGsaResult {
CaseType Type { get; }

//GsaResultsValues GetNodeDisplacementValues(string nodelist, LengthUnit lengthUnit);
ConcurrentDictionary<int, GsaResultsValues> GetNodeDisplacementValues(string nodelist, LengthUnit lengthUnit);

// etc.
}
Expand Down

0 comments on commit 1f8fe70

Please sign in to comment.