Skip to content

Commit 7decf6f

Browse files
committed
PDFBOX-5660: removve exception that isn't thrown, as suggested by Valery Bokov; closes #451
git-svn-id: https://svn.apache.org/repos/asf/pdfbox/trunk@1934550 13f79535-47bb-0310-9956-ffa450edef68
1 parent 6b9b255 commit 7decf6f

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

  • pdfbox/src/main/java/org/apache/pdfbox/pdmodel

pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDPage.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -245,10 +245,9 @@ else if (base instanceof COSArray)
245245
*
246246
* @return An InputStream, never null. Multiple content streams are concatenated and separated
247247
* with a newline. An empty stream is returned if the page doesn't have any content stream.
248-
* @throws IOException If the stream could not be read
249248
*/
250249
@Override
251-
public InputStream getContents() throws IOException
250+
public InputStream getContents()
252251
{
253252
RandomAccessRead contentsForRandomAccess = getContentsForRandomAccess();
254253
if (contentsForRandomAccess != null)
@@ -259,7 +258,7 @@ public InputStream getContents() throws IOException
259258
}
260259

261260
@Override
262-
public RandomAccessRead getContentsForStreamParsing() throws IOException
261+
public RandomAccessRead getContentsForStreamParsing()
263262
{
264263
// return a stream based reader if there is just one stream
265264
COSStream contentStream = page.getCOSStream(COSName.CONTENTS);
@@ -282,7 +281,7 @@ public RandomAccessRead getContentsForStreamParsing() throws IOException
282281
}
283282

284283
@Override
285-
public RandomAccessRead getContentsForRandomAccess() throws IOException
284+
public RandomAccessRead getContentsForRandomAccess()
286285
{
287286
COSStream contentStream = page.getCOSStream(COSName.CONTENTS);
288287
if (contentStream != null)

0 commit comments

Comments
 (0)