Skip to content

Commit 92e9de6

Browse files
committed
PDFBOX-5660: improve javadoc
git-svn-id: https://svn.apache.org/repos/asf/pdfbox/trunk@1928974 13f79535-47bb-0310-9956-ffa450edef68
1 parent 95ce874 commit 92e9de6

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

pdfbox/src/main/java/org/apache/pdfbox/rendering/PDFRenderer.java

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,9 @@ public void setImageDownscalingOptimizationThreshold(float imageDownscalingOptim
188188
* @param pageIndex the zero-based index of the page to be converted.
189189
* @return the rendered page image
190190
* @throws IOException if the PDF cannot be read
191+
* @throws IllegalStateException if the requested index isn't found or doesn't point to a valid
192+
* page dictionary
193+
* @throws IndexOutOfBoundsException if the requested index is higher than the page count
191194
*/
192195
public BufferedImage renderImage(int pageIndex) throws IOException
193196
{
@@ -201,6 +204,9 @@ public BufferedImage renderImage(int pageIndex) throws IOException
201204
* @param scale the scaling factor, where 1 = 72 DPI
202205
* @return the rendered page image
203206
* @throws IOException if the PDF cannot be read
207+
* @throws IllegalStateException if the requested index isn't found or doesn't point to a valid
208+
* page dictionary
209+
* @throws IndexOutOfBoundsException if the requested index is higher than the page count
204210
*/
205211
public BufferedImage renderImage(int pageIndex, float scale) throws IOException
206212
{
@@ -213,6 +219,9 @@ public BufferedImage renderImage(int pageIndex, float scale) throws IOException
213219
* @param dpi the DPI (dots per inch) to render at
214220
* @return the rendered page image
215221
* @throws IOException if the PDF cannot be read
222+
* @throws IllegalStateException if the requested index isn't found or doesn't point to a valid
223+
* page dictionary
224+
* @throws IndexOutOfBoundsException if the requested index is higher than the page count
216225
*/
217226
public BufferedImage renderImageWithDPI(int pageIndex, float dpi) throws IOException
218227
{
@@ -226,6 +235,9 @@ public BufferedImage renderImageWithDPI(int pageIndex, float dpi) throws IOExcep
226235
* @param imageType the type of image to return
227236
* @return the rendered page image
228237
* @throws IOException if the PDF cannot be read
238+
* @throws IllegalStateException if the requested index isn't found or doesn't point to a valid
239+
* page dictionary
240+
* @throws IndexOutOfBoundsException if the requested index is higher than the page count
229241
*/
230242
public BufferedImage renderImageWithDPI(int pageIndex, float dpi, ImageType imageType)
231243
throws IOException
@@ -240,6 +252,9 @@ public BufferedImage renderImageWithDPI(int pageIndex, float dpi, ImageType imag
240252
* @param imageType the type of image to return
241253
* @return the rendered page image
242254
* @throws IOException if the PDF cannot be read
255+
* @throws IllegalStateException if the requested index isn't found or doesn't point to a valid
256+
* page dictionary
257+
* @throws IndexOutOfBoundsException if the requested index is higher than the page count
243258
*/
244259
public BufferedImage renderImage(int pageIndex, float scale, ImageType imageType)
245260
throws IOException
@@ -256,6 +271,9 @@ public BufferedImage renderImage(int pageIndex, float scale, ImageType imageType
256271
* @param destination controlling visibility of optional content groups
257272
* @return the rendered page image
258273
* @throws IOException if the PDF cannot be read
274+
* @throws IllegalStateException if the requested index isn't found or doesn't point to a valid
275+
* page dictionary
276+
* @throws IndexOutOfBoundsException if the requested index is higher than the page count
259277
*/
260278
public BufferedImage renderImage(int pageIndex, float scale, ImageType imageType, RenderDestination destination)
261279
throws IOException
@@ -419,6 +437,9 @@ public void renderPageToGraphics(int pageIndex, Graphics2D graphics, float scale
419437
* @param scaleY the scale to draw the page at for the y-axis, where 1 = 72 DPI
420438
* @param destination controlling visibility of optional content groups
421439
* @throws IOException if the PDF cannot be read
440+
* @throws IllegalStateException if the requested index isn't found or doesn't point to a valid
441+
* page dictionary
442+
* @throws IndexOutOfBoundsException if the requested index is higher than the page count
422443
*/
423444
public void renderPageToGraphics(int pageIndex, Graphics2D graphics, float scaleX, float scaleY, RenderDestination destination)
424445
throws IOException

0 commit comments

Comments
 (0)