@Test(expected = DecodingException.class) public void decodeMessageShouldReturnRequestWhenCommandHasWrongDepthOptionName() throws DecodingException { InputStream inputStream = new ByteArrayInputStream((INBOX + " (DEPTHerr 1) (MAXSIZE 1024) (/shared/comment /private/comment) \n").getBytes(StandardCharsets.US_ASCII)); ImapRequestStreamLineReader lineReader = new ImapRequestStreamLineReader(inputStream, outputStream); parser.decode(lineReader, TAG, session); }
@Override protected ImapMessage decode(ImapRequestLineReader requestReader, Tag tag, ImapSession session) throws DecodingException { try { return buildAnnotationRequest(requestReader, tag); } catch (NullPointerException | IllegalArgumentException | IllegalStateException e) { throw new DecodingException(HumanReadableText.ILLEGAL_ARGUMENTS, e.getMessage(), e); } }
GetAnnotationCommandParser extends AbstractImapCommandParser { @Override protected ImapMessage decode(ImapRequestLineReader requestReader, Tag tag, ImapSession session) throws DecodingException { try { return buildAnnotationRequest(requestReader, tag); } catch (NullPointerException | IllegalArgumentException | IllegalStateException e) { throw new DecodingException(HumanReadableText.ILLEGAL_ARGUMENTS, e.getMessage(), e); } } }
GetAnnotationCommandParser extends AbstractImapCommandParser { @Override protected ImapMessage decode(ImapRequestLineReader requestReader, Tag tag, ImapSession session) throws DecodingException { try { return buildAnnotationRequest(requestReader, tag); } catch (NullPointerException | IllegalArgumentException | IllegalStateException e) { throw new DecodingException(HumanReadableText.ILLEGAL_ARGUMENTS, e.getMessage(), e); } } GetAnnotationCommandParser(StatusResponseFactory statusResponseFactory); }
GetAnnotationCommandParser extends AbstractImapCommandParser { @Override protected ImapMessage decode(ImapRequestLineReader requestReader, Tag tag, ImapSession session) throws DecodingException { try { return buildAnnotationRequest(requestReader, tag); } catch (NullPointerException | IllegalArgumentException | IllegalStateException e) { throw new DecodingException(HumanReadableText.ILLEGAL_ARGUMENTS, e.getMessage(), e); } } GetAnnotationCommandParser(StatusResponseFactory statusResponseFactory);  }
GetAnnotationCommandParser extends AbstractImapCommandParser { @Override protected ImapMessage decode(ImapRequestLineReader requestReader, Tag tag, ImapSession session) throws DecodingException { try { return buildAnnotationRequest(requestReader, tag); } catch (NullPointerException | IllegalArgumentException | IllegalStateException e) { throw new DecodingException(HumanReadableText.ILLEGAL_ARGUMENTS, e.getMessage(), e); } } GetAnnotationCommandParser(StatusResponseFactory statusResponseFactory);   }