private void radioButtonLink_CheckedChanged(object sender, EventArgs e) { if (radioButtonLink.Checked) { selectedSourceType = MassSource.OnlyLink; } }
private void radioButtonSelectedMass_CheckedChanged(object sender, EventArgs e) { if (radioButtonSelectedMass.Checked) { selectedSourceType = MassSource.SelectedMass; } }
private void radioButtonAll_CheckedChanged(object sender, EventArgs e) { if (radioButtonAll.Checked) { selectedSourceType = MassSource.DisplayAll; } }
/***************************************************/ private bool CreateObject(MassSource massSource) { bool includeElements = massSource.ElementSelfMass; bool includeAddMass = massSource.AdditionalMass; bool includeLoads = massSource.FactoredAdditionalCases.Count > 0; int count = massSource.FactoredAdditionalCases.Count; string[] cases = new string[count]; double[] factors = new double[count]; for (int i = 0; i < count; i++) { cases[i] = massSource.FactoredAdditionalCases[i].Item1.Name; factors[i] = massSource.FactoredAdditionalCases[i].Item2; } if (m_model.PropMaterial.SetMassSource_1(ref includeElements, ref includeAddMass, ref includeLoads, count, ref cases, ref factors) == 0) { } else { CreateElementError("mass source", massSource.Name); } return(true); }
/// <summary> /// Fills the class with all data from the application. /// </summary> public override void FillData() { base.FillData(); InitialCase.FillInitialCase(); MassSource.FillMassSource(); NonlinearSettings.FillData(); StageDefinitions.FillStageDefinitions(); StageDefinitions.FillStageOperations(); }
public Form_LinkedFiles(UIApplication uiapp) { m_app = uiapp; m_doc = m_app.ActiveUIDocument.Document; InitializeComponent(); selectedSourceType = MassSource.OnlyHost; CollectWorksets(); DisplayRvtLinkTypes(); FindSelectedMass(); }
/// <summary> /// Fills the class with all data from the application. /// </summary> public override void FillData() { base.FillData(); Loads.FillLoads(); InitialCase.FillInitialCase(); MassSource.FillMassSource(); ModalCase.FillModalCase(); NonlinearSettings.FillData(); FillResultsSaved(); FillLoadApplication(); }
/***************************************************/ private bool CreateObject(MassSource massSource) { bool includeElements = massSource.ElementSelfMass; bool includeAddMass = massSource.AdditionalMass; bool includeLoads = massSource.FactoredAdditionalCases.Count > 0; int count = massSource.FactoredAdditionalCases.Count; string[] cases = new string[count]; double[] factors = new double[count]; for (int i = 0; i < count; i++) { cases[i] = Helper.CaseNameToCSI(massSource.FactoredAdditionalCases[i].Item1); factors[i] = massSource.FactoredAdditionalCases[i].Item2; } return(m_model.PropMaterial.SetMassSource_1(ref includeElements, ref includeAddMass, ref includeLoads, count, ref cases, ref factors) == 0); }
/// <summary> /// Sets the mass source. /// </summary> /// <param name="model">The model.</param> /// <param name="table">The table.</param> internal static void SetMASS_SOURCE(Model model, List <Dictionary <string, string> > table) { foreach (Dictionary <string, string> tableRow in table) { MassSource massSource = model.Settings.ModelInformation.MassSources.FillItem(tableRow["MassSource"]); if (tableRow.ContainsKey("Elements")) { massSource.IsFromElements = Adaptor.fromYesNo(tableRow["Elements"]); massSource.IsFromMasses = Adaptor.fromYesNo(tableRow["Masses"]); massSource.IsDefault = Adaptor.fromYesNo(tableRow["IsDefault"]); massSource.IsFromLoads = Adaptor.fromYesNo(tableRow["Loads"]); } if (tableRow.ContainsKey("LoadPat")) { massSource.LoadPatterns.Add( new LoadPatternTuple { Load = model.Loading.Patterns[tableRow["LoadPat"]], ScaleFactor = Adaptor.toDouble(tableRow["Multiplier"]) }); } } }
/// <summary> /// Removes the mass source to be used for the analysis case. /// </summary> /// <exception cref="CSiException"><see cref="CSiApiBase.API_DEFAULT_ERROR_CODE" /></exception> public void RemoveMassSource() { _massSource = null; setMassSource(); }
/// <summary> /// Sets the mass source to be used for the analysis case. /// </summary> /// <exception cref="CSiException"><see cref="CSiApiBase.API_DEFAULT_ERROR_CODE" /></exception> public void SetMassSource(MassSource massSource) { _massSource = massSource; setMassSource(); }
/// <summary> /// Retrieves the mass source to be used for the analysis case. /// </summary> /// <exception cref="CSiException"><see cref="CSiApiBase.API_DEFAULT_ERROR_CODE" /></exception> public void FillMassSource() { _massSource = new MassSource(_app?.GetMassSource(CaseName)); }
/// <summary> /// Retrieves the mass source to be used for the analysis case. /// </summary> /// <exception cref="CSiException"><see cref="CSiApiBase.API_DEFAULT_ERROR_CODE" /></exception> public void FillMassSource() { _massSource = new MassSource(_apiApp, _apiMassSource?.GetMassSource(CaseName)); }