Class OdfIndex
Represents the abstract base class for indexes in an ODF document. 表示 ODF 文件中索引的抽象基底類別。
public abstract class OdfIndex
- Inheritance
-
OdfIndex
- Derived
- Inherited Members
Constructors
OdfIndex(OdfNode, TextDocument)
protected OdfIndex(OdfNode node, TextDocument doc)
Parameters
nodeOdfNodeThe associated OdfNode. / 相關聯的 OdfNode 節點。
docTextDocumentThe owning text document. / 所屬的文字文件。
Fields
Doc
The owning text document. 所屬的文字文件。
protected readonly TextDocument Doc
Field Value
Properties
BodyNode
Gets the index's body node. 取得索引的本文節點。
public OdfNode? BodyNode { get; }
Property Value
- OdfNode
Name
Gets or sets the name of the index. 取得或設定索引的名稱。
public string Name { get; set; }
Property Value
Node
Gets the OdfNode associated with this index. 取得與此索引相關聯的 OdfNode 節點。
public OdfNode Node { get; }
Property Value
- OdfNode
SourceNode
Gets the index's source node. 取得索引的來源節點。
public OdfNode? SourceNode { get; }
Property Value
- OdfNode
Methods
FindChild(OdfNode, string, string)
Finds the first child matching the specified XML local name and namespace. 尋找符合指定 XML 本地名稱與命名空間的第一個子專案。
protected OdfNode? FindChild(OdfNode parent, string localName, string ns)
Parameters
parentOdfNodeThe parent node. / 父節點。
localNamestringThe XML local name. / XML 本地名稱。
nsstringThe namespace URI. / 命名空間 URI。
Returns
- OdfNode
The matching child, or
nullif none exists. / 符合條件的子專案,若無則傳回null。
FindOrCreateChild(OdfNode, string, string, string)
Finds or creates a child matching the specified XML local name and namespace. 尋找或建立符合指定 XML 本地名稱與命名空間的子專案。
protected OdfNode FindOrCreateChild(OdfNode parent, string localName, string ns, string prefix)
Parameters
parentOdfNodeThe parent node. / 父節點。
localNamestringThe XML local name. / XML 本地名稱。
nsstringThe namespace URI. / 命名空間 URI。
prefixstringThe namespace prefix. / 命名空間前綴。
Returns
- OdfNode
The existing or newly created child node. / 現有的或新建立的子節點。
GetSourceLocalName()
Gets the XML local name of the index source node. 取得索引來源節點的 XML 本地名稱。
protected abstract string GetSourceLocalName()
Returns
- string
The XML local name. / XML 本地名稱。
Update()
Updates the index content. 更新索引內容。
public abstract void Update()