GeometryGym.Ifc.ParserIfc.parseValue C# (CSharp) Méthode

parseValue() static private méthode

static private parseValue ( string str ) : IfcValue
str string
Résultat IfcValue
        internal static IfcValue parseValue(string str)
        {
            IfcMeasureValue mv = parseMeasureValue(str);
            if (mv != null)
                return mv;
            IfcSimpleValue sv = parseSimpleValue(str);
            if (sv != null)
                return sv;
            return parseDerivedMeasureValue(str);
        }

Usage Example

        internal override void parse(string str, ref int pos, ReleaseVersion release, int len, ConcurrentDictionary <int, BaseClassIfc> dictionary)
        {
            mName        = ParserSTEP.StripString(str, ref pos, len);
            mDescription = ParserSTEP.StripString(str, ref pos, len);
            string s = ParserSTEP.StripField(str, ref pos, len);

            if (s.StartsWith("IFC"))
            {
                mAppliedValue = ParserIfc.parseValue(s);
            }
            else
            {
                mAppliedValue = dictionary[ParserSTEP.ParseLink(s)] as IfcAppliedValueSelect;
            }
            mUnitBasis = ParserSTEP.StripLink(str, ref pos, len);
            if (release < ReleaseVersion.IFC4)
            {
                mSSApplicableDate = dictionary[ParserSTEP.StripLink(str, ref pos, len)] as IfcDateTimeSelect;
                mSSFixedUntilDate = dictionary[ParserSTEP.StripLink(str, ref pos, len)] as IfcDateTimeSelect;
            }
            else
            {
                mApplicableDate = IfcDate.ParseSTEP(ParserSTEP.StripString(str, ref pos, len));
                mFixedUntilDate = IfcDate.ParseSTEP(ParserSTEP.StripString(str, ref pos, len));
                mCategory       = ParserSTEP.StripString(str, ref pos, len);
                mCondition      = ParserSTEP.StripString(str, ref pos, len);
                s = ParserSTEP.StripField(str, ref pos, len);
                if (s.StartsWith("."))
                {
                    Enum.TryParse <IfcArithmeticOperatorEnum>(s.Replace(".", ""), true, out mArithmeticOperator);
                }
                mComponents = ParserSTEP.StripListLink(str, ref pos, len);
            }
        }
All Usage Examples Of GeometryGym.Ifc.ParserIfc::parseValue