示例#1
0
        public static BbPropertyEnumerated Create(string name, bool value)
        {
            var sp = new BbPropertyEnumerated(name, value);

            BbInstanceDB.AddToExport(sp);
            return(sp);
        }
示例#2
0
        protected BbStatus(
            BbPropertySet bbPropertySet,
            string status,
            string changeStatus,
            bool?approved
            )
        {
            BbPropertySet = bbPropertySet;
            if (!string.IsNullOrWhiteSpace(status))
            {
                Status = status;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("Status", Status, true));
            }

            if (!string.IsNullOrWhiteSpace(changeStatus))
            {
                ChangeStatus = changeStatus;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("ChangeStatus", ChangeStatus, true));
            }
            if (approved != null)
            {
                Approved = approved.Value;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Approved", Approved));
            }
        }
 public void AddRectangleOpeningProperty(BbPropertySet bbPropertySet, string featureSubType,
                                         double rectangleOpeningWidth,
                                         double rectangleOpeningHeight,
                                         double rectangleOpeningRoundRadius)
 {
     bbPropertySet.AddProperty(BbPropertyEnumerated.Create("FeatureSubtype", featureSubType, true));
     bbPropertySet.AddProperty(BbSingleProperty.Create("RectangleOpeningWidth", rectangleOpeningWidth, typeof(IfcPositiveLengthMeasure)));
     bbPropertySet.AddProperty(BbSingleProperty.Create("RectangleOpeningHeight", rectangleOpeningHeight, typeof(IfcPositiveLengthMeasure)));
     bbPropertySet.AddProperty(BbSingleProperty.Create("RectangleOpeningRoundRadius", rectangleOpeningRoundRadius, typeof(IfcPositiveLengthMeasure)));
 }
示例#4
0
 public void AddSlottedHoleProperty(BbPropertySet bbPropertySet, string featureSubType,
                                    double slotHoleCenterToCenter,
                                    double slotHoleLength,
                                    double slotHoleWidth)
 {
     bbPropertySet.AddProperty(BbPropertyEnumerated.Create("FeatureSubtype", featureSubType, true));
     bbPropertySet.AddProperty(BbSingleProperty.Create("SlotHoleCenterToCenter", slotHoleCenterToCenter, typeof(IfcPositiveLengthMeasure)));
     bbPropertySet.AddProperty(BbSingleProperty.Create("SlotHoleLength", slotHoleLength, typeof(IfcPositiveLengthMeasure)));
     bbPropertySet.AddProperty(BbSingleProperty.Create("SlotHoleWidth", slotHoleWidth, typeof(IfcPositiveLengthMeasure)));
 }
        protected BbBoltHoleProperties(
            BbPropertySet bbPropertySet,
            string fabricationMethod,
            string criticalFace,
            string designConstraint,
            string featureSubTypes,
            double boltHoleDiameter,
            bool?partialHoleIndicator,
            double partialHoleDepth
            )
        {
            BbPropertySet = bbPropertySet;

            if (!string.IsNullOrWhiteSpace(fabricationMethod))
            {
                FabricationMethod = fabricationMethod;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("Fabrication Method", FabricationMethod, true));
            }

            if (!string.IsNullOrWhiteSpace(criticalFace))
            {
                CriticalFace = criticalFace;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("Critical Face", CriticalFace, true));
            }

            if (!string.IsNullOrWhiteSpace(designConstraint))
            {
                DesignConstraint = designConstraint;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("Design Constraint", DesignConstraint, true));
            }

            if (!string.IsNullOrWhiteSpace(featureSubTypes))
            {
                FeatureSubTypes = featureSubTypes;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("Feature Sub Types", FeatureSubTypes, true));
            }

            if (!double.IsPositiveInfinity(boltHoleDiameter))
            {
                BoltHoleDiameter = boltHoleDiameter;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Bolt Hole Diameter", BoltHoleDiameter, typeof(IfcPositiveLengthMeasure)));
            }
            if (partialHoleIndicator != null)
            {
                PartialHoleIndicator = partialHoleIndicator.Value;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Partial Hole Indicator", PartialHoleIndicator));
            }

            if (!double.IsPositiveInfinity(partialHoleDepth) && partialHoleDepth > 0)
            {
                PartialHoleDepth = partialHoleDepth;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Partial Hole Depth", PartialHoleDepth, typeof(IfcPositiveLengthMeasure)));
            }
        }
示例#6
0
        protected BbCastellation(
            BbPropertySet bbPropertySet,
            string castellationType,
            double castellationEndPostWidth1,
            double castellationEndPostWidth2,
            double castellationSpacing,
            double castellationHeight,
            double castellationWidth,
            double castellationDepth
            )
        {
            BbPropertySet = bbPropertySet;
            if (!string.IsNullOrWhiteSpace(castellationType))
            {
                CastellationType = castellationType;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("Castellation Type", CastellationType, true));
            }

            if (!double.IsPositiveInfinity(castellationEndPostWidth1))
            {
                CastellationEndPostWidth1 = castellationEndPostWidth1;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Castellation End Post Width1", CastellationEndPostWidth1, typeof(IfcPositiveLengthMeasure)));
            }

            if (!double.IsPositiveInfinity(castellationEndPostWidth2))
            {
                CastellationEndPostWidth2 = castellationEndPostWidth2;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Castellation End Post Width2", CastellationEndPostWidth2, typeof(IfcPositiveLengthMeasure)));
            }

            if (!double.IsPositiveInfinity(castellationSpacing))
            {
                CastellationSpacing = castellationSpacing;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Castellation Spacing", CastellationSpacing, typeof(IfcPositiveLengthMeasure)));
            }

            if (!double.IsPositiveInfinity(castellationHeight))
            {
                CastellationHeight = castellationHeight;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Castellation Height", CastellationHeight, typeof(IfcPositiveLengthMeasure)));
            }

            if (!double.IsPositiveInfinity(castellationWidth))
            {
                CastellationWidth = castellationWidth;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Castellation Width", CastellationWidth, typeof(IfcPositiveLengthMeasure)));
            }

            if (!double.IsPositiveInfinity(castellationDepth))
            {
                CastellationDepth = castellationDepth;
                bbPropertySet.AddProperty(BbSingleProperty.Create("Castellation Depth", CastellationDepth, typeof(IfcPositiveLengthMeasure)));
            }
        }
 protected BbDrillHoleProperty(
     BbPropertySet bbPropertySet,
     string featureSubType,
     double boltHoleDiameter,
     bool partialHoleIndicator,
     double partialHoleDepth
     )
 {
     BoltHoleDiameter     = boltHoleDiameter;
     PartialHoleIndicator = partialHoleIndicator;
     PartialHoleDepth     = partialHoleDepth;
     BbPropertySet        = bbPropertySet;
     bbPropertySet.AddProperty(BbPropertyEnumerated.Create("FeatureSubtype", featureSubType, true));
     bbPropertySet.AddProperty(BbSingleProperty.Create("BoltHoleDiameter", boltHoleDiameter, typeof(IfcPositiveLengthMeasure)));
     bbPropertySet.AddProperty(BbSingleProperty.Create("PartialHoleIndicator", partialHoleIndicator));
     bbPropertySet.AddProperty(BbSingleProperty.Create("PartialHoleDepth", partialHoleDepth, typeof(IfcPositiveLengthMeasure)));
 }
示例#8
0
        protected BbSchedule(
            BbPropertySet bbPropertySet,
            string phaseSequence,
            string sequenceLevel,
            DateTime onSiteBy
            )
        {
            BbPropertySet = bbPropertySet;
            if (!string.IsNullOrWhiteSpace(phaseSequence))
            {
                PhaseSequence = phaseSequence;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("PhaseSequence", PhaseSequence, true));
            }

            if (!string.IsNullOrWhiteSpace(sequenceLevel))
            {
                SequenceLevel = sequenceLevel;
                bbPropertySet.AddProperty(BbPropertyEnumerated.Create("SequenceLevel", SequenceLevel, true));
            }

            OnSiteBy = onSiteBy;
            bbPropertySet.AddProperty(BbSingleProperty.Create("OnSiteBy", OnSiteBy));
        }
 public static BbPropertyEnumerated Create(string name, double value, Type type)
 {
     var sp = new BbPropertyEnumerated(name, value, type);
     BbInstanceDB.AddToExport(sp);
     return sp;
 }