Inheritance: GeometryGym.Ifc.IfcPhysicalSimpleQuantity
Example #1
0
        internal static void parseFields(IfcQuantityLength q, List <string> arrFields, ref int ipos, ReleaseVersion schema)
        {
            IfcPhysicalSimpleQuantity.parseFields(q, arrFields, ref ipos);
            string str = arrFields[ipos++];

            if (!double.TryParse(str, out q.mLengthValue))
            {
                if (str.StartsWith("IFCLENGTHMEASURE"))
                {
                    str = str.Substring(17, str.Length - 18);
                    double.TryParse(str, out q.mLengthValue);
                }
            }
            if (schema != ReleaseVersion.IFC2x3)
            {
                q.mFormula = arrFields[ipos++].Replace("'", "");
            }
        }
Example #2
0
        internal static IfcQuantityLength Parse(string str, ReleaseVersion schema)
        {
            IfcQuantityLength q = new IfcQuantityLength();
            int pos = 0, len = str.Length;

            q.Parse(str, ref pos, len);
            string s = ParserSTEP.StripField(str, ref pos, len);

            if (!double.TryParse(s, System.Globalization.NumberStyles.Any, ParserSTEP.NumberFormat, out q.mLengthValue))
            {
                if (s.StartsWith("IFCLENGTHMEASURE"))
                {
                    s = s.Substring(17, s.Length - 18);
                    double.TryParse(s, out q.mLengthValue);
                }
            }
            if (schema != ReleaseVersion.IFC2x3)
            {
                q.mFormula = ParserSTEP.StripString(str, ref pos, len);
            }
            return(q);
        }
Example #3
0
 internal IfcQuantityLength(DatabaseIfc db, IfcQuantityLength q) : base(db, q)
 {
     mLengthValue = q.mLengthValue; mFormula = q.mFormula;
 }
Example #4
0
 internal static IfcQuantityLength Parse(string str, ReleaseVersion schema)
 {
     IfcQuantityLength q = new IfcQuantityLength();
     int pos = 0, len = str.Length;
     q.Parse(str, ref pos, len);
     string s = ParserSTEP.StripField(str, ref pos, len);
     if (!double.TryParse(s, System.Globalization.NumberStyles.Any, ParserSTEP.NumberFormat, out q.mLengthValue))
     {
         if (s.StartsWith("IFCLENGTHMEASURE"))
         {
             s = s.Substring(17, s.Length - 18);
             double.TryParse(s, out q.mLengthValue);
         }
     }
     if (schema != ReleaseVersion.IFC2x3)
         q.mFormula = ParserSTEP.StripString(str, ref pos, len);
     return q;
 }
Example #5
0
 internal static void parseFields(IfcQuantityLength q, List<string> arrFields, ref int ipos, ReleaseVersion schema)
 {
     IfcPhysicalSimpleQuantity.parseFields(q, arrFields, ref ipos);
     string str = arrFields[ipos++];
     if (!double.TryParse(str, out q.mLengthValue))
     {
         if (str.StartsWith("IFCLENGTHMEASURE"))
         {
             str = str.Substring(17, str.Length - 18);
             double.TryParse(str, out q.mLengthValue);
         }
     }
     if (schema != ReleaseVersion.IFC2x3)
         q.mFormula = arrFields[ipos++].Replace("'", "");
 }
Example #6
0
 internal IfcQuantityLength(DatabaseIfc db, IfcQuantityLength q)
     : base(db,q)
 {
     mLengthValue = q.mLengthValue; mFormula = q.mFormula;
 }
Example #7
0
		internal IfcQuantityLength(IfcQuantityLength q) : base(q) { mLengthValue = q.mLengthValue; }
Example #8
0
		internal static IfcQuantityLength Parse(string strDef, Schema schema) { IfcQuantityLength q = new IfcQuantityLength(); int ipos = 0; parseFields(q, ParserSTEP.SplitLineFields(strDef), ref ipos, schema); return q; }
Example #9
0
 internal static IfcQuantityLength Parse(string strDef, ReleaseVersion schema)
 {
     IfcQuantityLength q = new IfcQuantityLength(); int ipos = 0; parseFields(q, ParserSTEP.SplitLineFields(strDef), ref ipos, schema); return(q);
 }
Example #10
0
 internal IfcQuantityLength(IfcQuantityLength q) : base(q)
 {
     mLengthValue = q.mLengthValue;
 }