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

#include <IAutoFindFileUtils.h>

Inheritance diagram for IAutoFindFileUtils:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IAUTOFINDFILEUTILS }
 

Public Member Functions

virtual bool16 AutoFindFile (const IDFile &dir, const IDFile &oldFile, IDFile *newFile)=0
 
virtual bool AutoFindFile (const IDFile &dir, const IDFile &oldFile, IDFile &newFile)=0
 
virtual void HFSPathToPOSIXPath (const WideString &hfsPath, WideString &posixPath) const =0
 
virtual bool16 AutoFindFile (const IDFile &dir, const URI &oldURI, URI &newURI)=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

IAutoFindFileUtils is used to automatically find/resolve missing files. The utility first attempts to find the file relative to the given directory. If no file is found, the utility will attempt to find the file in the application's IDirList directory list.

Member Function Documentation

virtual bool16 IAutoFindFileUtils::AutoFindFile (const IDFiledir,
const IDFileoldFile,
IDFilenewFile 
)
pure virtual

Attempts to automatically (find without user interaction) the file with the same name of the missing file.

Parameters
dir[IN] Relative location of where to start the search.
oldFile[IN] Original path to the missing file.
newFile[OUT] New path of the missing file.
Returns
kTrue if missing file was found, else kFalse.
virtual bool IAutoFindFileUtils::AutoFindFile (const IDFiledir,
const IDFileoldFile,
IDFilenewFile 
)
pure virtual

Attempts to automatically (find without user interaction) the file with the same name of the missing file.

Parameters
dir[IN] Relative location of where to start the search.
oldFile[IN] Original path to the missing file.
newFile[OUT] New path of the missing file.
Returns
True if missing file was found, else false.
virtual bool16 IAutoFindFileUtils::AutoFindFile (const IDFiledir,
const URIoldURI,
URInewURI 
)
pure virtual

Attempts to automatically (find without user interaction) the URI with the same name of the missing URI.

Parameters
dir[IN] Relative location of where to start the search.
oldURI[IN] Original URI to the missing file.
newURI[OUT] New URI of the missing file.
Returns
kTrue if missing URI was found, else kFalse.
virtual void IAutoFindFileUtils::HFSPathToPOSIXPath (const WideStringhfsPath,
WideStringposixPath 
) const
pure virtual

Naively converts a HFS path to a POSIX path by adding a slash to the front of the path, replacing colons with forward slashes, and replacing forward slashes with colons. \ No attempt is made to validate the HFS path before conversion.

Parameters
hfsPath[IN] HFS path to convert.
posixPath[OUT] Resulting POSIX path.