JoinElementWraper.cs 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. using Autodesk.Revit.DB;
  2. using System;
  3. using System.Collections.Generic;
  4. using System.Linq;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. namespace FWindSoft.Revit.Mep
  8. {
  9. /*
  10. * 关联对象可以写成泛型形式,可传入Pipe,Conduit,Duct等,但现在没必要写的这么细
  11. * 弱化设计时的限定,在运行时执行时,在动态判定
  12. */
  13. /// <summary>
  14. /// 连接对象封装
  15. /// </summary>
  16. public class JoinElementWraper
  17. {
  18. public JoinElementWraper(Element element)
  19. {
  20. AssociateElement = element;
  21. IsFamilyInstance = element is FamilyInstance;
  22. }
  23. /// <summary>
  24. /// 关联元素
  25. /// </summary>
  26. public Element AssociateElement { get; private set; }
  27. /// <summary>
  28. /// 连接过程中使用到的连接点
  29. /// </summary>
  30. public Connector UseConnector { get; set; }
  31. /// <summary>
  32. /// 标志是否是设备
  33. /// </summary>
  34. public bool IsFamilyInstance { get;private set; }
  35. }
  36. }