コード例 #1
0
 private void radioButtonLink_CheckedChanged(object sender, EventArgs e)
 {
     if (radioButtonLink.Checked)
     {
         selectedSourceType = MassSource.OnlyLink;
     }
 }
コード例 #2
0
 private void radioButtonSelectedMass_CheckedChanged(object sender, EventArgs e)
 {
     if (radioButtonSelectedMass.Checked)
     {
         selectedSourceType = MassSource.SelectedMass;
     }
 }
コード例 #3
0
 private void radioButtonAll_CheckedChanged(object sender, EventArgs e)
 {
     if (radioButtonAll.Checked)
     {
         selectedSourceType = MassSource.DisplayAll;
     }
 }
コード例 #4
0
        /***************************************************/

        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);
        }
コード例 #5
0
 /// <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();
 }
コード例 #6
0
        public Form_LinkedFiles(UIApplication uiapp)
        {
            m_app = uiapp;
            m_doc = m_app.ActiveUIDocument.Document;

            InitializeComponent();
            selectedSourceType = MassSource.OnlyHost;
            CollectWorksets();
            DisplayRvtLinkTypes();
            FindSelectedMass();
        }
コード例 #7
0
 /// <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();
 }
コード例 #8
0
        /***************************************************/

        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);
        }
コード例 #9
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"])
                    });
                }
            }
        }
コード例 #10
0
 /// <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();
 }
コード例 #11
0
 /// <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();
 }
コード例 #12
0
 /// <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));
 }
コード例 #13
0
 /// <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));
 }