InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IIndexingDataSuite Class Referenceabstract

#include <IIndexingDataSuite.h>

Inheritance diagram for IIndexingDataSuite:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IINDEXINGDATASUITE }
 

Public Member Functions

virtual bool16 CanCreateIndex ()=0
 
virtual bool16 CanGenerateIndex ()=0
 
virtual bool16 CanUpdateIndex ()=0
 
virtual void GetSelectedIndexStory (UIDRef &selectedIndexStory)=0
 
virtual void GetSelectedText (WideString &selectedText)=0
 
virtual void GetIndexMarkOfSelection (UID &indexMarkUID)=0
 
virtual ErrorCode CreatePageReference (const IndexTopicEntry &entry, IIndexPageEntryData::PageRangeType pageRangeType, UID nextStyleUID, int32 numOfParOrPage, UID styleUID, bool16 updateSelection=kTrue, bool16 sortPRefs=kTrue)=0
 
virtual ErrorCode CreatePageReference1 (const IndexTopicEntry &entry, IIndexPageEntryData::PageRangeType pageRangeType, UID nextStyleUID, int32 numOfParOrPage, UID styleUID, UIDRef textModelUIDRef, int32 start, int32 end, bool16 updateSelection=kTrue, bool16 sortPRefs=kTrue)=0
 
virtual ErrorCode CreatePageReferences (IIndexPageEntryData::PageRangeType pageRangeType, UID nextStyleUID, int32 numOfParOrPage, UID styleUID, bool16 updateSelection=kTrue, bool16 sortPRefs=kTrue, bool16 reversedNames=kFalse)=0
 
virtual ErrorCode CreatePageReferences1 (TopicEntryInfoArray const &entries, IIndexPageEntryData::PageRangeType pageRangeType, UID nextStyleUID, int32 numOfParOrPage, UID styleUID, UIDRef textModelUIDRef, bool16 updateSelection=kTrue, bool16 sortPRefs=kTrue)=0
 
virtual ErrorCode CreateTopicEntriesForTopicList (UIDRef topicList, bool16 bReversedNames)=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

Defines the interface for a index data suite to be used in the new selection architecture.

Member Enumeration Documentation

anonymous enum

kDefaultIID

Member Function Documentation

virtual bool16 IIndexingDataSuite::CanCreateIndex ()
pure virtual

Check if we can create a index based on the current selection.

Returns
bool16 kTrue if we can, kFalse otherwise.
virtual bool16 IIndexingDataSuite::CanGenerateIndex ()
pure virtual

Check if we can generate index story.

Returns
bool16 kTrue if we can, kFalse otherwise.
virtual bool16 IIndexingDataSuite::CanUpdateIndex ()
pure virtual

Check if we can update index story. We can only update index in the following cases: 1) In layout mode, text focus/text selection is within an index story; 2) In layout mode, only one text frame is selected and it is an index story; 3) In story editor mode, story is an index story.

Returns
bool16 kTrue if we can, kFalse otherwise.
virtual ErrorCode IIndexingDataSuite::CreatePageReference (const IndexTopicEntryentry,
IIndexPageEntryData::PageRangeType pageRangeType,
UID nextStyleUID,
int32 numOfParOrPage,
UID styleUID,
bool16 updateSelection = kTrue,
bool16 sortPRefs = kTrue 
)
pure virtual

Create a page reference index.

Parameters
entrydescribe the index entry itself.
pageRangeTypedescribes the option to create a page range in index.
nextStyleUIDdescribes the paragraph style that the page range extends from the index marker to the next change of the paragraph style.
numOfParOrPagedescribe the number of paragraphs/pages to which the page range extends from index marker.
styleUIDdescribe the paragraph style that the page range extends from the index marker to the page where the next occurrence of the paragraph style.
updateSelectionis a flag determining if we need to update the selection after creating page reference.
sortPRefsis a flag determining if we need to sort the page references.
Returns
ErrorCode as the execution result.
virtual ErrorCode IIndexingDataSuite::CreatePageReference1 (const IndexTopicEntryentry,
IIndexPageEntryData::PageRangeType pageRangeType,
UID nextStyleUID,
int32 numOfParOrPage,
UID styleUID,
UIDRef textModelUIDRef,
int32 start,
int32 end,
bool16 updateSelection = kTrue,
bool16 sortPRefs = kTrue 
)
pure virtual

This is another version for CreatePageReference. See CreatePageReference for the explanation of this function. Due to a bug in make_functor which fail to recognize same function name with different signature, I rename the function to avoid the limitation. Talked to Mat Marcus and he will fix it soon.

Parameters
entrydescribe the index entry itself.
pageRangeTypedescribes the option to create a page range in index.
nextStyleUIDdescribes the paragraph style that the page range extends from the index marker to the next change of the paragraph style.
numOfParOrPagedescribe the number of paragraphs/pages to which the page range extends from index marker.
styleUIDdescribe the paragraph style that the page range extends from the index marker to the page where the next occurrence of the paragraph style.
updateSelectionis a flag determining if we need to update the selection after creating page reference.
sortPRefsis a flag determining if we need to sort the page references.
virtual ErrorCode IIndexingDataSuite::CreatePageReferences (IIndexPageEntryData::PageRangeType pageRangeType,
UID nextStyleUID,
int32 numOfParOrPage,
UID styleUID,
bool16 updateSelection = kTrue,
bool16 sortPRefs = kTrue,
bool16 reversedNames = kFalse 
)
pure virtual

Creates page references with the word(s) selected in the text.

Parameters
pageRangeTypedescribes the option to create a page range in index.
nextStyleUIDdescribes the paragraph style that the page range extends from the index marker to the next change of the paragraph style.
numOfParOrPagedescribe the number of paragraphs/pages to which the page range extends from index marker.
styleUIDdescribe the paragraph style that the page range extends from the index marker to the page where the next occurrence of the paragraph style.
updateSelectionis a flag determining if we need to update the selection after creating page reference.
sortPRefsis a flag determining if we need to sort the page references.
bReversedNames[in] - if the entries should have a <LastName, FirstName> form.
Returns
ErrorCode as the execution result.
virtual ErrorCode IIndexingDataSuite::CreatePageReferences1 (TopicEntryInfoArray const & entries,
IIndexPageEntryData::PageRangeType pageRangeType,
UID nextStyleUID,
int32 numOfParOrPage,
UID styleUID,
UIDRef textModelUIDRef,
bool16 updateSelection = kTrue,
bool16 sortPRefs = kTrue 
)
pure virtual

This is another version for CreatePageReference. See CreatePageReference for the explanation of this function. Due to a bug in make_functor which fail to recognize same function name with different signature, I rename the function to avoid the limitation. Talked to Mat Marcus and he will fix it soon.

Parameters
entries[in]- array of pairs IndexTopicEntry and text indexes that will be used to create the page references.
pageRangeTypedescribes the option to create a page range in index.
nextStyleUIDdescribes the paragraph style that the page range extends from the index marker to the next change of the paragraph style.
numOfParOrPagedescribe the number of paragraphs/pages to which the page range extends from index marker.
styleUIDdescribe the paragraph style that the page range extends from the index marker to the page where the next occurrence of the paragraph style.
updateSelectionis a flag determining if we need to update the selection after creating page reference.
sortPRefsis a flag determining if we need to sort the page references.
virtual ErrorCode IIndexingDataSuite::CreateTopicEntriesForTopicList (UIDRef topicList,
bool16 bReversedNames 
)
pure virtual

Creates one or more topic entries into a topic list.

Parameters
topicList[in] - the topic list where the entries will be added.
bReversedNames[in] - if the entries should have a <LastName, FirstName> form.
Returns
ErrorCode as the execution result.
virtual void IIndexingDataSuite::GetIndexMarkOfSelection (UIDindexMarkUID)
pure virtual

Get index mark from the current selection.

Parameters
indexMarkUIDwith UID of index mark.
Returns
void
virtual void IIndexingDataSuite::GetSelectedIndexStory (UIDRefselectedIndexStory)
pure virtual

Get the UIDRef of the selected index story.

Parameters
UIDRef— if no story is selected or selected story is not an index story, set selectedIndexStory as UIDRef(nil, kInvalidUID); otherwise, return the selectedIndexStory
Returns
void
virtual void IIndexingDataSuite::GetSelectedText (WideStringselectedText)
pure virtual

Get the current selection.

Parameters
selectedTextwith the selected content.
Returns
void