/// <summary> /// 螺钉组的构造函数; /// </summary> /// <param name="boltArray"></param> public CMrBoltArray(TSM.BoltArray boltArray, TSD.Bolt boltInDrawing) { mName = "BoltArray"; mBoltArrayInModel = boltArray; mBoltInDrawing = boltInDrawing; mBoltArrayShapeType = MrBoltArrayShapeType.ARRAY; mMrBoltArrayInfo = new CMrBoltArrayInfo(this); }
/// <summary> /// 计算BoltArray的形状; /// </summary> public void InitBoltArrayShape() { if (mMrBoltList.Count() == 0) { return; } MrSlopeType mrSlopeType = CDimTools.GetInstance().JudgeLineSlope(mFirstPoint, mSecondPoint); if (mrSlopeType == MrSlopeType.EQUAL_ZERO || mrSlopeType == MrSlopeType.INFINITY || mMrBoltList.Count == 0) { mBoltArrayShapeType = MrBoltArrayShapeType.ARRAY; } else if (mrSlopeType == MrSlopeType.MORETHAN_ZERO || mrSlopeType == MrSlopeType.LESSTHAN_ZERO) { mBoltArrayShapeType = MrBoltArrayShapeType.OBLIQUELINE; } }