2011-02-08 36 views
2

我正在用Sandcastle構建API文檔。該代碼有多個標記爲廢棄的類和方法。現在我想要在API文檔輸出中明確標記這些方法(劃掉或其他標記)。然而,Sandcastle輸出完全不標記過時的方法/類。如何在sandcastle中標記輸出中的過時類/方法

我的問題是。我需要做什麼才能擁有由Sandcastle標記的過時方法/類。

感謝您的任何建議/幫助。

回答

2

嗯,我發現這個問題。這個問題是我使用的API和屬性過濾器的混合。

所以我增加了系統的命名空間中我的API過濾器,所以它包括過時的屬性:

<apiFilter> 
    <namespace name="System" expose="true"> 
    <type name="ObsoleteAttribute" expose="true" /> 
    <type name="SerializableAttribute" expose="false" /> 
    </namespace> 
    <!-- rest of the stuff --> 
</apiFilter> 

而且加入這也給屬性過濾器列表:

<attributeFilter expose="true"> 
    <namespace name="System" expose="false"> 
    <type name="ObsoleteAttribute" expose="true" /> 
    </namespace> 
    <!-- rest of the stuff --> 
</attributeFilter> 

我的屬性過濾器中有'ObsoleteAttribute',但沒有在API過濾器中。

此線程也有幫助:http://docproject.codeplex.com/discussions/74716?ProjectName=docproject

相關問題