Full-Text Search
-
Support for database encryption. If you intend to use database encryption features, you must provide an implementation of
See morePSPDFDatabaseEncryptionProvider
by setting-[PSPDFKitGlobal setDatabaseEncryptionProvider:]
.Declaration
Objective-C
@protocol PSPDFDatabaseEncryptionProvider <NSObject>
Swift
protocol DatabaseEncryptionProvider : NSObjectProtocol
-
This class encapsulates the metadata associated with a document used in the PSPDFLibraryFileSystemDataSource
See moreDeclaration
Objective-C
@interface PSPDFFileIndexItemDescriptor : NSObject <NSSecureCoding>
Swift
class FileIndexItemDescriptor : NSObject, NSSecureCoding
-
PSPDFLibrary
implements a sqlite-based full-text-search engine. You set a data source that provides the documents to be indexed by the library, and then call -updateIndex, which performs its work asynchronously. Then, you can search for keywords within that collection. Typically, you use aPSPDFLibraryFileSystemDataSource
. There can be multiple libraries, although usually one is enough for the common use case. Furthermore, when using multiple libraries with spotlight indexing enabled could lead to duplicates in users’ spotlight results. See https://pspdfkit.com/guides/ios/features/indexed-full-text-search/ for further documentation.Note
Requires theFeatures.indexedFTS
feature flag.Declaration
Objective-C
@interface PSPDFLibrary : NSObject
Swift
class PDFLibrary : NSObject
-
A library data source that indexes all documents in a specified directory. This class will automatically add and remove files from the library based on changes in the directory.
See moreDeclaration
Objective-C
@interface PSPDFLibraryFileSystemDataSource : NSObject <PSPDFLibraryDataSource>
Swift
class LibraryFileSystemDataSource : NSObject, LibraryDataSource
-
This class is a subclass of
See morePSPDFSearchResult
, and encapsulates a preview generated byPSPDFLibrary
. Mainly, it prevents access of theannotation
property ofPSPDFSearchResult
, and instead provides anannotationObjectNumber
property to represent a matched annotation.Declaration
Objective-C
@interface PSPDFLibraryPreviewResult : PSPDFSearchResult
Swift
class LibraryPreviewResult : SearchResult
-
See moreUITableViewCell
subclass representing a document. Used inPSPDFDocumentPickerController
.Declaration
Objective-C
@interface PSPDFDocumentPickerCell : PSPDFTableViewCell
Swift
class PDFDocumentPickerCell : PDFTableViewCell
-
Shows all documents available in the specified directory or the documents set directly. By default this will enqueue all documents into the default
PSPDFLibrary
for FTS.Uses a
UISearchController
internally. It displays results for both PDF text and annotations, provided the library indexes both.Note
This controller should be presented embedded in aUINavigationController
. Failing to do so might lead to issues with the search UI.Declaration
Objective-C
@interface PSPDFDocumentPickerController : PSPDFSearchableTableViewController <UISearchDisplayDelegate, UISearchBarDelegate>
Swift
class PDFDocumentPickerController : SearchableTableViewController, UISearchDisplayDelegate, UISearchBarDelegate
-
Shows status of indexing while we’re indexing or searching.
Declaration
Objective-C
@interface PSPDFDocumentPickerIndexStatusCell : PSPDFSpinnerCell
Swift
class DocumentPickerIndexStatusCell : PDFSpinnerCell