Esempio n. 1
0
            /// <summary>
            /// Vergleich Fußbodenhöhe mit Höhenkotenwert
            /// </summary>
            /// <remarks>Schreibt ErrorPoistions</remarks>
            ///
            internal void CheckRaumHoehe()
            {
                ErrorPositions.Clear();

                foreach (var raumOid in RaumBlocks)
                {
                    CheckRaumHoehe(raumOid);
                }
            }
Esempio n. 2
0
            /// <summary>
            /// Vergleich Fußbodenhöhe mit Höhenkotenwert
            /// </summary>
            /// <remarks>Schreibt ErrorPoistions</remarks>
            ///
            internal void CheckFb()
            {
                ErrorPositions.Clear();

                foreach (var hkOid in HKBlocks)
                {
                    CheckFb(hkOid);
                }
            }
Esempio n. 3
0
 public void ListErrors()
 {
     if (ErrorPositions.ContainsKey(posNow.LineNumber))
     {
         var list = ErrorPositions[posNow.LineNumber];
         if (list != null)
         {
             for (int i = 0; i < list.Count; i++)
             {
                 PrintError(i);
                 currNumError++;
             }
         }
     }
 }
Esempio n. 4
0
            private void CompareHeights(ObjectId vpOid, ObjectId hkOid)
            {
                using (var trans = _AcAp.Application.DocumentManager.MdiActiveDocument.TransactionManager.StartTransaction())
                {
                    BlockReference vpBlock = (BlockReference)trans.GetObject(vpOid, OpenMode.ForRead);
                    BlockReference hkBlock = (BlockReference)trans.GetObject(hkOid, OpenMode.ForRead);

                    double hkHeight = GetHkHeight(hkBlock);

                    int diff = (int)Math.Round((Math.Abs(vpBlock.Position.Z - hkHeight) * 100.0));
                    if (diff > HoePrOptions.FbToleranz)
                    {
                        ErrorPositions.Add(hkBlock.Position);
                    }

                    trans.Commit();
                }
            }
Esempio n. 5
0
        public void error(int code, TextPosition textPosition)
        {
            if (numErrorInLine == Constants.CountErrorInLine)
            {
                ErrorOverflow = true;
            }
            else
            {
                if (textPosition.LineNumber == lastLineError)
                {
                    numErrorInLine++;
                }
                else
                {
                    lastLineError  = posNow.LineNumber;
                    numErrorInLine = 1;
                }

                NumError++;
                if (!ErrorPositions.ContainsKey(textPosition.LineNumber))
                {
                    ErrorPositions.Add(textPosition.LineNumber, new List <ErrorPosition>()
                    {
                        new ErrorPosition()
                        {
                            ErrCode   = code,
                            Line      = textPosition.LineNumber,
                            PosInLine = textPosition.PosInLine
                        }
                    });
                }
                else
                {
                    ErrorPositions[textPosition.LineNumber].Add(new ErrorPosition()
                    {
                        ErrCode   = code,
                        Line      = textPosition.LineNumber,
                        PosInLine = textPosition.PosInLine
                    });
                }
            }
        }
Esempio n. 6
0
            private void CompareHeights(ObjectId fpOid, ObjectId dpOid, ObjectId rbOid)
            {
                using (var trans = _AcAp.Application.DocumentManager.MdiActiveDocument.TransactionManager.StartTransaction())
                {
                    BlockReference fbBlock    = (BlockReference)trans.GetObject(fpOid, OpenMode.ForRead);
                    BlockReference dpBlock    = (BlockReference)trans.GetObject(dpOid, OpenMode.ForRead);
                    Entity         raumEntity = (Entity)trans.GetObject(rbOid, OpenMode.ForRead);
                    var            rbpos      = GetRbPosition(raumEntity);

                    double raumHoehe;
                    if (GetRaumHoehe(raumEntity, out raumHoehe))
                    {
                        double vpDiff = dpBlock.Position.Z - fbBlock.Position.Z;

                        int diff = (int)Math.Round((Math.Abs(vpDiff - raumHoehe) * 100.0));
                        if (diff > HoePrOptions.RhToleranz)
                        {
                            ErrorPositions.Add(rbpos);
                        }
                    }

                    trans.Commit();
                }
            }