PSPDFInstantError

Undocumented

  • The error is unknown to PSPDF Instant. The underlying error will be placed in NSUnderlyingErrorKey in the userInfo.

    Declaration

    Objective-C

    PSPDFInstantErrorUnknown = 1

    Swift

    case unknown = 1
  • The feature you were trying to use is not supported in the context of PSPDF Instant.

    Declaration

    Objective-C

    PSPDFInstantErrorFeatureUnsupported = 2

    Swift

    case featureUnsupported = 2
  • The document that you were trying to operate on is invalid or unknown to PSPDF Instant.

    Declaration

    Objective-C

    PSPDFInstantErrorInvalidDocument = 3

    Swift

    case invalidDocument = 3
  • The JWT you provided to authenticate has been rejected.

    This error code is relevant when you are attempting to update the authentication token for a document descriptor: Since the access to a document can be revoked at any time, it is possible that even a freshly obtained JWT is rejected by the PSPDF Instant server when you try to update the authentication token for a document. When this happens, your delegate will receive a document:didFailUpdatingAuthenticationTokenWithError: callback with this error code. Note that the document’s storage will not be removed from disk! You can still access that document, and even continue to make edits to it. These will, however, not be synced anymore.

    Declaration

    Objective-C

    PSPDFInstantErrorAccessDenied = 4

    Swift

    case accessDenied = 4
  • Error indicating an attempt was made to download a document that has already been downloaded. The error will have a document descriptor under PSPDFInstantErrorDocumentDescriptorKey in the user info.

    Declaration

    Objective-C

    PSPDFInstantErrorAlreadyDownloaded = 5

    Swift

    case alreadyDownloaded = 5
  • Reading from or writing to the annotation database failed.

    Whenever possible, the SQLite (extended) error code can be found under the user info key as an NSNumber

    Declaration

    Objective-C

    PSPDFInstantErrorDatabaseAccessFailed = 6

    Swift

    case databaseAccessFailed = 6
  • Writing a PDF or metadata file to disk failed. - note: This does not refer to database errors: Those will be reported with PSPDFInstantErrorDatabaseAccessFailed, with an appropriate SQLite extended error code. Instead, this error code is relevant for downloading documents.

    Declaration

    Objective-C

    PSPDFInstantErrorCouldNotWriteToDisk = 7

    Swift

    case couldNotWriteToDisk = 7
  • Error returned when an attempt is made to save a document managed by PSPDF Instant. The error will have a document under PSPDFInstantErrorDocumentKey in the user info.

    Declaration

    Objective-C

    PSPDFInstantErrorSavingDisabled = 9

    Swift

    case savingDisabled = 9
  • Error returned when the document passed into -[PSPDFInstantDocumentDescriptor annotationWithIdentifier:forDocument:error] is not managed by the receiver.

    Declaration

    Objective-C

    PSPDFInstantErrorUnmanagedDocument = 10

    Swift

    case unmanagedDocument = 10
  • Error returned when the receiver does not know of an annotation for the identifier passed into -[PSPDFInstantDocumentDescriptor annotationWithIdentifier:forDocument:error].

    Declaration

    Objective-C

    PSPDFInstantErrorNoSuchAnnotation = 11

    Swift

    case noSuchAnnotation = 11
  • Error returned when the annotation passed into -[PSPDFInstantDocumentDescriptor identifierForAnnotation:error:] is not managed by the receiver.

    Declaration

    Objective-C

    PSPDFInstantErrorUnmanagedAnnotation = 12

    Swift

    case unmanagedAnnotation = 12
  • The operation could not be completed because the network request failed. This happens when offline.

    If you were syncing manually, retry at a later date. If you are using PSPDFInstantDocumentDescriptor’s automatic syncing via startListeningForServerChanges, or are using PSPDFInstantViewController, there is not much for you to do: a re-attempt to sync will be scheduled at an appropriate time. However, you may still want to inform your users, that their local changes are not synced, though.

    Declaration

    Objective-C

    PSPDFInstantErrorRequestFailed = 16

    Swift

    case requestFailed = 16
  • The operation could not be completed because the server sent invalid data.

    If you ever see this error, please send a support request (https://pspdfkit.com/support/request)

    Declaration

    Objective-C

    PSPDFInstantErrorInvalidServerData = 17

    Swift

    case invalidServerData = 17
  • The operation could not be completed because the server rejected the request as invalid.

    If you ever see this error, please send a support request (https://pspdfkit.com/support/request)

    Declaration

    Objective-C

    PSPDFInstantErrorInvalidRequest = 18

    Swift

    case invalidRequest = 18
  • The operation could not be completed because the client and server have incompatible versions: the server expects a newer client. You need to update this framework in your app to a compatible version and release an update. If a user sees this on their device they need to update your app.

    By default when this error is encountered PSPDFInstantViewController shows an alert to the user saying an app update is needed. If you have your own error handling for this situation you can disable that with the shouldShowCriticalErrors property.

    Declaration

    Objective-C

    PSPDFInstantErrorOldClient = 21

    Swift

    case oldClient = 21
  • The operation could not be completed because the client and server have incompatible versions: the client is too new for the server. The server needs to be updated to a compatible version. You should update your server before releasing the updated client to ensure this error is never encountered on users’ devices.

    Declaration

    Objective-C

    PSPDFInstantErrorOldServer = 22

    Swift

    case oldServer = 22