MCPcopy Create free account
hub / github.com/LibPDF-js/core / canSaveIncrementally

Method canSaveIncrementally

src/api/pdf.ts:3162–3173  ·  view source on GitHub ↗

* Check if incremental save is possible. * * Returns null if possible, or the blocker reason if not.

()

Source from the content-addressed store, hash-verified

3160 * Returns null if possible, or the blocker reason if not.
3161 */
3162 canSaveIncrementally(): IncrementalSaveBlocker | null {
3163 const pendingAction = this._pendingSecurity.action;
3164
3165 return checkIncrementalSaveBlocker({
3166 isNewlyCreated: this._isNewlyCreated,
3167 isLinearized: this.isLinearized,
3168 recoveredViaBruteForce: this.recoveredViaBruteForce,
3169 encryptionChanged: pendingAction !== "none",
3170 encryptionAdded: pendingAction === "encrypt" && !this.isEncrypted,
3171 encryptionRemoved: pendingAction === "remove",
3172 });
3173 }
3174
3175 // ─────────────────────────────────────────────────────────────────────────────
3176 // Saving

Callers 8

saveInternalMethod · 0.95
ensureIncrementalSaveMethod · 0.80
pdf.test.tsFile · 0.80
mainFunction · 0.80
mainFunction · 0.80
mainFunction · 0.80

Calls 1

Tested by

no test coverage detected