@Test(expected = ParserException.class) public void testParseIntFieldZero() { parser.parseIntField(0); }
protected int parseIntField(int length) { if (length == 0) { throw new ParserException("Cannot parse int of size 0"); } return ArrayConverter.bytesToInt(parseByteArrayField(length)); }
Parser { protected int parseIntField(int length) { if (length == 0) { throw new ParserException("Cannot parse int of size 0"); } return ArrayConverter.bytesToInt(parseByteArrayField(length)); } }
Parser { protected int parseIntField(int length) { if (length == 0) { throw new ParserException("Cannot parse int of size 0"); } return ArrayConverter.bytesToInt(parseByteArrayField(length)); } Parser(int startposition, byte[] array); }
Parser { protected int parseIntField(int length) { if (length == 0) { throw new ParserException("Cannot parse int of size 0"); } return ArrayConverter.bytesToInt(parseByteArrayField(length)); } Parser(int startposition, byte[] array); int getPointer(); void setPointer(int pointer); int getStartPoint(); abstract T parse(); }
Parser { protected int parseIntField(int length) { if (length == 0) { throw new ParserException("Cannot parse int of size 0"); } return ArrayConverter.bytesToInt(parseByteArrayField(length)); } Parser(int startposition, byte[] array); int getPointer(); void setPointer(int pointer); int getStartPoint(); abstract T parse();  }