1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 |
- /* ==============================================================================
- * 功能描述:CheckBase
- * 创 建 者:Garrett
- * 创建日期:2019/6/11 16:01:26
- * ==============================================================================*/
- using System;
- using System.Collections.Generic;
- using Autodesk.Revit.DB;
- using Newtonsoft.Json;
- namespace ServiceRevitLib.Mode
- {
- /// <summary>
- /// CheckBase
- /// </summary>
- public class CheckBase:ResultBase
- {
- public CheckBase()
- {
- Content=new List<ResultBase>();
- }
- private string m_Name;
- /// <summary>
- /// 检查项名称
- /// </summary>
- public string Name
- {
- get { return this.GetType().Name; }
- }
- public List<ResultBase> Content { get; set; }
- /// <summary>
- /// 关联表的名称
- /// </summary>
- [JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
- public string ReferenceSheet { get; set; }
- #region Method
-
- protected Document m_Doc { get; set; }
- public void SetDoc(Document doc)
- {
- m_Doc = doc;
- }
- public virtual void Check()
- {
- if(m_Doc==null)throw new NullReferenceException();
- Console.WriteLine(this.Name + "Checked");
- }
- #endregion
- }
- }
|