Inheritance: BaseClassIfc, IfcUnit
示例#1
0
        internal double ScaleSI(IfcDerivedUnitEnum unitType)
        {
            IfcDerivedUnit derivedUnit = this[unitType];

            if (derivedUnit != null)
            {
                return(derivedUnit.SIFactor);
            }
            return(1);
        }
示例#2
0
 internal double getScaleSI(IfcDerivedUnitEnum unitType)
 {
     foreach (IfcUnit u in Units)
     {
         IfcDerivedUnit du = u as IfcDerivedUnit;
         if (du != null)
         {
         }
     }
     return(1);
 }
示例#3
0
 internal IfcDerivedUnit Find(IfcDerivedUnitEnum unit)
 {
     foreach (IfcUnit u in Units)
     {
         IfcDerivedUnit du = u as IfcDerivedUnit;
         if (du != null && du.UnitType == unit)
         {
             return(du);
         }
     }
     return(null);
 }
示例#4
0
 public IfcDerivedUnit this[IfcDerivedUnitEnum unit]
 {
     get
     {
         foreach (IfcUnit u in Units)
         {
             IfcDerivedUnit du = u as IfcDerivedUnit;
             if (du != null && du.UnitType == unit)
             {
                 return(du);
             }
         }
         return(null);
     }
 }
示例#5
0
		internal static IfcDerivedUnit Parse(string strDef) { IfcDerivedUnit u = new IfcDerivedUnit(); int ipos = 0; parseFields(u, ParserSTEP.SplitLineFields(strDef), ref ipos); return u; }
示例#6
0
		internal static void parseFields(IfcDerivedUnit u, List<string> arrFields, ref int ipos) { u.mElements = ParserSTEP.SplitListLinks(arrFields[ipos++]); u.mUnitType = (IfcDerivedUnitEnum)Enum.Parse(typeof(IfcDerivedUnitEnum), arrFields[ipos++].Replace(".", "")); u.mUserDefinedType = arrFields[ipos++]; }
示例#7
0
		//internal string UserDefinedType { get { } }

		internal IfcDerivedUnit(IfcDerivedUnit v) : base() { mElements = new List<int>(v.mElements.ToArray()); mUnitType = v.mUnitType; mUserDefinedType = v.mUserDefinedType; }
示例#8
0
		internal IfcDerivedUnit(DatabaseIfc db, IfcDerivedUnit u) : base(db) { Elements = u.Elements.ConvertAll(x=>db.Factory.Duplicate(x) as IfcDerivedUnitElement); mUnitType = u.mUnitType; mUserDefinedType = u.mUserDefinedType; }