<index-entries>

Description

A collection of book index metadata items.

PDF

The BDML indexing system works by searching for key phrases in the document's titles, headings and paragraphs. The key phrases are specified via <index-entries> metadata entries, placed in the root or any included BDML documents' metadata section.

Attributes

No attributes are defined for the <index-entries> element.

Immediate descendants

Element name Description
<item> An index item.

Immediate ancestors

Element name Relation
<metadata> The enclosing metadata element.

Example

<document xmlns="http://boradoc.org/1.0">
  <metadata>
    <index-entries>
      <item entry="unit">
        <match entry="unit" />
        <match entry="test" search="unit test" />
        <match entry="test" search="unit tests" />
        <match entry="testing" search="unit testing" />
      </item>
      <item entry="code">
        <match entry="C++" />
        <match entry="C++ file" search=".cpp" />
        <match entry="C++ file" search=".hpp" />
        <match entry="Java" />
        <match entry="Java file" search=".java" />
      </item>
    </index-entries>
  </metadata>
  <-- Main document contents follows. -->
</document>

The above BDML renders to the following in the document's index:

unit - 42

test - 123, 154

testing - 123

code

C++ - 23, 184

C++ file - 23, 24, 185

Java - 32, 45, 89

Java file - 186