Exemplo n.º 1
0
        /// <inheritdoc />
        /// <summary>
        /// Returns the case type, design type, and auto flag for the specified load case.
        /// </summary>
        /// <param name="nameLoadCase">The name of an existing load case.</param>
        /// <param name="loadCaseType">Load case type corresponding to the name provided.</param>
        /// <param name="loadCaseSubType">Load case sub-type corresponding to the name provided.</param>
        /// <param name="designType">Load case design type corresponding to the name provided.</param>
        /// <param name="designTypeOption">Load case type corresponding to the name provided.</param>
        /// <param name="autoCreatedCase">This is a value indicating if the load case has been automatically created.</param>
        /// <exception cref="CSiException"><see cref="CSiApiBase.API_DEFAULT_ERROR_CODE" /></exception>
        public void GetCaseTypes(string nameLoadCase,
                                 out eLoadCaseType loadCaseType,
                                 out int loadCaseSubType,
                                 out eLoadPatternType designType,
                                 out eSpecificationSource designTypeOption,
                                 out eAutoCreatedCase autoCreatedCase)
        {
            loadCaseType    = 0;
            loadCaseSubType = 0;
            designType      = 0;
            CSiProgram.eLoadCaseType    csiCaseType    = CSiProgram.eLoadCaseType.Modal;
            CSiProgram.eLoadPatternType csiPatternType = CSiProgram.eLoadPatternType.Dead;

            int csiDesignTypeOption = 0;
            int csiAutoCreatedCase  = 0;

            _callCode = _sapModel.LoadCases.GetTypeOAPI_1(nameLoadCase, ref csiCaseType, ref loadCaseSubType, ref csiPatternType, ref csiDesignTypeOption, ref csiAutoCreatedCase);
            if (throwCurrentApiException(_callCode))
            {
                throw new CSiException(API_DEFAULT_ERROR_CODE);
            }

            loadCaseType     = EnumLibrary.Convert(csiCaseType, loadCaseType);
            designType       = EnumLibrary.Convert(csiPatternType, designType);
            designTypeOption = (eSpecificationSource)csiDesignTypeOption;
            autoCreatedCase  = (eAutoCreatedCase)csiAutoCreatedCase;
        }
Exemplo n.º 2
0
        // === Get/Set


        /// <summary>
        /// This function retrieves the load type for a specified load pattern.
        /// </summary>
        /// <param name="name">The name of an existing load pattern.</param>
        /// <param name="loadPatternType">This is one of the items in the eLoadPatternType enumeration.</param>
        /// <exception cref="CSiException"></exception>
        public void GetLoadType(string name,
                                ref eLoadPatternType loadPatternType)
        {
            CSiProgram.eLoadPatternType csiLoadPatternType = CSiProgram.eLoadPatternType.Other;
            _callCode = _sapModel.LoadPatterns.GetLoadType(name, ref csiLoadPatternType);

            if (throwCurrentApiException(_callCode))
            {
                throw new CSiException();
            }

            loadPatternType = EnumLibrary.Convert(csiLoadPatternType, loadPatternType);
        }
Exemplo n.º 3
0
        // === Get/Set

        /// <inheritdoc />
        /// <summary>
        /// Returns the load type for a specified load pattern.
        /// </summary>
        /// <param name="name">The name of an existing load pattern.</param>
        /// <exception cref="CSiException"><see cref="CSiApiBase.API_DEFAULT_ERROR_CODE" /></exception>
        public eLoadPatternType GetLoadType(string name)
        {
            eLoadPatternType loadPatternType = 0;

            CSiProgram.eLoadPatternType csiLoadPatternType = CSiProgram.eLoadPatternType.Other;
            _callCode = _sapModel.LoadPatterns.GetLoadType(name, ref csiLoadPatternType);

            if (throwCurrentApiException(_callCode))
            {
                throw new CSiException(API_DEFAULT_ERROR_CODE);
            }

            return(EnumLibrary.Convert(csiLoadPatternType, loadPatternType));
        }
Exemplo n.º 4
0
 internal static eLoadPatternType FromCSi(CSiProgram.eLoadPatternType enumValue)
 {
     return((eLoadPatternType)enumValue);
 }