/// <summary> /// Sets the frame loads point. /// </summary> /// <param name="model">The model.</param> /// <param name="table">The table.</param> private static void setFRAME_LOADS_POINT(Model model, List <Dictionary <string, string> > table) { foreach (Dictionary <string, string> tableRow in table) { Frame frame = model.Structure.Frames[tableRow["Frame"]]; RelativeAbsoluteCoordinate distanceFromI = new RelativeAbsoluteCoordinate(frame.Length) { UseRelativeDistance = (tableRow["DistType"] == "RelDist") }; if (distanceFromI.UseRelativeDistance) { distanceFromI.RelativeDistance = Adaptor.toDouble(tableRow["RelDist"]); } else { distanceFromI.ActualDistance = Adaptor.toDouble(tableRow["AbsDist"]); } FrameLoadPoint load = new FrameLoadPoint { LoadPattern = tableRow["LoadPat"], CoordinateSystem = tableRow["CoordSys"], ForceType = Enums.EnumLibrary.ConvertStringToEnumByDescription <eLoadForceType>(tableRow["Type"]), LoadDirection = Enums.EnumLibrary.ConvertStringToEnumByDescription <eLoadDirection>(tableRow["Dir"]), DistanceFromI = distanceFromI, GUID = tableRow["GUID"], }; if (tableRow.ContainsKey("Force")) { load.PointLoadValue = Adaptor.toDouble(tableRow["Force"]); } if (tableRow.ContainsKey("Moment")) { load.PointLoadValue = Adaptor.toDouble(tableRow["Moment"]); } frame.AddLoadPoint(load); } }
/// <summary> /// Initializes a new instance of the <see cref="FrameLoadPoint"/> class. /// </summary> /// <param name="frameLength">Length of the frame.</param> public FrameLoadPoint(double frameLength = 0) { DistanceFromI = new RelativeAbsoluteCoordinate(frameLength); }