com.aspose.words
Class BookmarksOutlineLevelCollection

java.lang.Object
    extended by com.aspose.words.BookmarksOutlineLevelCollection
All Implemented Interfaces:
java.lang.Iterable

public class BookmarksOutlineLevelCollection 
extends java.lang.Object

A collection of individual bookmarks outline level.

Key is a case-insensitive string bookmark name. Value is a int bookmark outline level.

Bookmark outline level may be a value from 0 to 9. Specify 0 and Word bookmark will not be displayed in the document outline. Specify 1 and Word bookmark will be displayed in the document outline at level 1; 2 for level 2 and so on.


Constructor Summary
BookmarksOutlineLevelCollection()
          
 
Property Getters/Setters Summary
intgetCount()
           Gets the number of elements contained in the collection.
intget(int index)
voidset(int index, int value)
           Gets or sets a bookmark outline level at the specified index.
intget(java.lang.String name)
voidset(java.lang.String name, int value)
           Gets or a sets a bookmark outline level by the bookmark name.
 
Method Summary
voidadd(java.lang.String name, int outlineLevel)
           Adds a bookmark to the collection.
voidclear()
           Removes all elements from the collection.
booleancontains(java.lang.String name)
           Determines whether the collection contains a bookmark with the given name.
intindexOfKey(java.lang.String name)
           Returns the zero-based index of the specified bookmark in the collection.
java.util.Iteratoriterator()
           Returns an iterator object that can be used to iterate over all items in the collection.
voidremove(java.lang.String name)
           Removes a bookmark with the specified name from the collection.
voidremoveAt(int index)
           Removes a bookmark at the specified index.
 

Constructor Detail

BookmarksOutlineLevelCollection

public BookmarksOutlineLevelCollection()

Property Getters/Setters Detail

getCount

public int getCount()
Gets the number of elements contained in the collection.

get/set

public int get(int index) / public void set(int index, int value)
Gets or sets a bookmark outline level at the specified index.
Parameters:
index - Zero-based index of the bookmark.
Returns:
The outline level of the bookmark. Valid range is 0 to 9.

get/set

public int get(java.lang.String name) / public void set(java.lang.String name, int value)
Gets or a sets a bookmark outline level by the bookmark name.
Parameters:
name - Case-insensitive name of the bookmark.
Returns:
The outline level of the bookmark. Valid range is 0 to 9.

Method Detail

add

public void add(java.lang.String name, int outlineLevel)
Adds a bookmark to the collection.
Parameters:
name - The case-insensitive name of the bookmark to add.
outlineLevel - The outline level of the bookmark. Valid range is 0 to 9.

clear

public void clear()
Removes all elements from the collection.

contains

public boolean contains(java.lang.String name)
Determines whether the collection contains a bookmark with the given name.
Parameters:
name - Case-insensitive name of the bookmark to locate.
Returns:
True if item is found in the collection; otherwise, false.

indexOfKey

public int indexOfKey(java.lang.String name)
Returns the zero-based index of the specified bookmark in the collection.
Parameters:
name - The case-insensitive name of the bookmark.
Returns:
The zero based index. Negative value if not found.

iterator

public java.util.Iterator iterator()
Returns an iterator object that can be used to iterate over all items in the collection.

remove

public void remove(java.lang.String name)
Removes a bookmark with the specified name from the collection.
Parameters:
name - The case-insensitive name of the bookmark.

removeAt

public void removeAt(int index)
Removes a bookmark at the specified index.
Parameters:
index - The zero based index.

See Also:
          Aspose.Words Documentation - the home page for the Aspose.Words Product Documentation.
          Aspose.Words Support Forum - our preferred method of support.