/** * This will tell if the next byte to be read is an end of line byte. * * @return true if the next byte is 0x0A or 0x0D. * * @throws IOException If there is an error reading from the stream. */ protected boolean isEOL() throws IOException { return isEOL(seqSource.peek()); }
/** * This will tell if the next byte is whitespace or not. * * @return true if the next byte in the stream is a whitespace character. * * @throws IOException If there is an error reading from the stream. */ protected boolean isWhitespace() throws IOException { return isWhitespace(seqSource.peek()); }
/** * This will tell if the next byte is a digit or not. * * @return true if the next byte in the stream is a digit. * * @throws IOException If there is an error reading from the stream. */ protected boolean isDigit() throws IOException { return isDigit(seqSource.peek()); }
/** * This will tell if the next byte is a space or not. * * @return true if the next byte in the stream is a space character. * * @throws IOException If there is an error reading from the stream. */ protected boolean isSpace() throws IOException { return isSpace(seqSource.peek()); }
/** * This will tell if the next character is a closing brace( close of PDF array ). * * @return true if the next byte is ']', false otherwise. * * @throws IOException If an IO error occurs. */ protected boolean isClosing() throws IOException { return isClosing(seqSource.peek()); }
/** * Checks if the next char is a space or a return. * * @return true if the next char is a space or a return * @throws IOException if something went wrong */ private boolean hasNextSpaceOrReturn() throws IOException { return isSpaceOrReturn( seqSource.peek() ); } }
char c = (char) seqSource.peek(); if( c == 't' )
if (isCR(c) && isLF(seqSource.peek()))
if (!seqSource.isEOF() && seqSource.peek() == 'e')
private void parseCOSDictionaryNameValuePair(COSDictionary obj) throws IOException { COSName key = parseCOSName(); COSBase value = parseCOSDictionaryValue(); skipSpaces(); if (((char) seqSource.peek()) == 'd') { // if the next string is 'def' then we are parsing a cmap stream // and want to ignore it, otherwise throw an exception. String potentialDEF = readString(); if (!potentialDEF.equals(DEF)) { seqSource.unread(potentialDEF.getBytes(ISO_8859_1)); } else { skipSpaces(); } } if (value == null) { LOG.warn("Bad dictionary declaration at offset " + seqSource.getPosition()); } else { // label this item as direct, to avoid signature problems. value.setDirect(true); obj.setItem(key, value); } }
char c = (char) seqSource.peek(); if (c == '>')
skipSpaces(); int i; while( ((i = seqSource.peek()) > 0) && ((char)i != ']') )
/** * This will tell if the next byte is whitespace or not. * * @return true if the next byte in the stream is a whitespace character. * * @throws IOException If there is an error reading from the stream. */ protected boolean isWhitespace() throws IOException { return isWhitespace(seqSource.peek()); }
/** * This will tell if the next byte is a digit or not. * * @return true if the next byte in the stream is a digit. * * @throws IOException If there is an error reading from the stream. */ protected boolean isDigit() throws IOException { return isDigit(seqSource.peek()); }
/** * This will tell if the next byte is a space or not. * * @return true if the next byte in the stream is a space character. * * @throws IOException If there is an error reading from the stream. */ protected boolean isSpace() throws IOException { return isSpace(seqSource.peek()); }
/** * This will tell if the next character is a closing brace( close of PDF array ). * * @return true if the next byte is ']', false otherwise. * * @throws IOException If an IO error occurs. */ protected boolean isClosing() throws IOException { return isClosing(seqSource.peek()); }
/** * Checks if the next char is a space or a return. * * @return true if the next char is a space or a return * @throws IOException if something went wrong */ private boolean hasNextSpaceOrReturn() throws IOException { return isSpaceOrReturn( seqSource.peek() ); } }