001: /*
002: * Copyright (c) 2007, intarsys consulting GmbH
003: *
004: * Redistribution and use in source and binary forms, with or without
005: * modification, are permitted provided that the following conditions are met:
006: *
007: * - Redistributions of source code must retain the above copyright notice,
008: * this list of conditions and the following disclaimer.
009: *
010: * - Redistributions in binary form must reproduce the above copyright notice,
011: * this list of conditions and the following disclaimer in the documentation
012: * and/or other materials provided with the distribution.
013: *
014: * - Neither the name of intarsys nor the names of its contributors may be used
015: * to endorse or promote products derived from this software without specific
016: * prior written permission.
017: *
018: * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
019: * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
020: * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
021: * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
022: * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
023: * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
024: * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
025: * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
026: * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
027: * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
028: * POSSIBILITY OF SUCH DAMAGE.
029: */
030: package de.intarsys.pdf.crypt;
031:
032: /**
033: * A document permissions set based on the "user access permissions" defined in
034: * a /Standard encryption dictionary.
035: *
036: */
037: public interface IAccessPermissions {
038: /**
039: * Assemble the document: insert, rotate or delete pages and create
040: * bookmarks or thumbnail images.
041: *
042: * @return if the document may be assembled
043: */
044: public abstract boolean mayAssemble();
045:
046: /**
047: * Copy or otherwise extract text and graphics from the document in support
048: * of accessibility to disabled users or for other purposes.
049: *
050: * @return if parts of the document may be copied
051: */
052: public abstract boolean mayCopy();
053:
054: /**
055: * Extract text and graphics (in support of accessibility to disabled users
056: * or for other purposes)
057: *
058: * @return if parts of the document may be extracted
059: */
060: public abstract boolean mayExtract();
061:
062: /**
063: * Fill in existing interactive form fields (including signature fields)
064: *
065: * @return if form fields may be filled
066: */
067: public abstract boolean mayFillForm();
068:
069: /**
070: * Modify the contents of the document by operations other than those
071: * controlled by mayModifyAnnotation and mayFillForm
072: *
073: * @return if document may be modified
074: */
075: public abstract boolean mayModify();
076:
077: /**
078: * Add or modify text annotations, fill in interactice form fields, and if
079: * mayModify is set, create or modify interactive form fields (including
080: * signature fields)
081: *
082: * @return if annotations may be modified
083: */
084: public abstract boolean mayModifyAnnotation();
085:
086: /**
087: * Print the document
088: *
089: * @return if the document may be printed
090: */
091: public abstract boolean mayPrint();
092:
093: /**
094: * Print the document to a representation from which a faithful digital copy
095: * of the PDF content could be generated. When this premission is not set
096: * and mayPrint is set, printing is limited to a low-level representation of
097: * the appearance, possibly of degraded quality.
098: *
099: * @return if the document may be high quality printed
100: */
101: public abstract boolean mayPrintHighQuality();
102: }
|