Full-Text Search

  • Support for database encryption. If you intend to use database encryption features, you must provide an implementation of PSPDFDatabaseEncryptionProvider by setting -[PSPDFKitGlobal setDatabaseEncryptionProvider:].

    See more

    Declaration

    Objective-C

    @protocol PSPDFDatabaseEncryptionProvider <NSObject>

    Swift

    protocol DatabaseEncryptionProvider : NSObjectProtocol
  • This class encapsulates the metadata associated with a document used in the PSPDFLibraryFileSystemDataSource

    See more

    Declaration

    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 a PSPDFLibraryFileSystemDataSource. 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/current/features/indexed-full-text-search/ for further documentation.

    Note

    Requires the PSPDFFeatureMaskIndexedFTS feature flag.
    See more

    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 more

    Declaration

    Objective-C

    
    @interface PSPDFLibraryFileSystemDataSource : NSObject <PSPDFLibraryDataSource>

    Swift

    class LibraryFileSystemDataSource : NSObject, LibraryDataSource
  • This class is a subclass of PSPDFSearchResult, and encapsulates a preview generated by PSPDFLibrary. Mainly, it prevents access of the annotation property of PSPDFSearchResult, and instead provides an annotationObjectNumber property to represent a matched annotation.

    See more

    Declaration

    Objective-C

    
    @interface PSPDFLibraryPreviewResult : PSPDFSearchResult

    Swift

    class LibraryPreviewResult : SearchResult
  • UITableViewCell subclass representing a document. Used in PSPDFDocumentPickerController.

    See more

    Declaration

    Objective-C

    
    @interface PSPDFDocumentPickerCell : PSPDFTableViewCell

    Swift

    class PDFDocumentPickerCell : PDFTableViewCell
  • Shows all documents available in the specified directory or the the documents set directly. By default this will enqueue all documents into the default PSPDFLibrary for FTS.

    Uses a UISearchController internally.

    Note

    This controller should be presented embedded in a UINavigationController. Failing to do so might lead to issues with the search UI.
    See more

    Declaration

    Objective-C

    
    @interface PSPDFDocumentPickerController
        : PSPDFStatefulTableViewController <UISearchDisplayDelegate,
                                            UISearchBarDelegate>

    Swift

    class PDFDocumentPickerController : StatefulTableViewController, UISearchDisplayDelegate, UISearchBarDelegate
  • Shows status of indexing while we’re indexing or searching.

    Declaration

    Objective-C

    
    @interface PSPDFDocumentPickerIndexStatusCell : PSPDFSpinnerCell

    Swift

    class DocumentPickerIndexStatusCell : PDFSpinnerCell