@Test public void encodeShouldWriteNilDelimiterWhenUnassigned() throws Exception { ListResponse input = new ListResponse(Children.HAS_CHILDREN, Selectability.NONE, nameParameter, ((char) Character.UNASSIGNED)); ListingEncodingUtils.encodeListingResponse(LIST_COMMAND, composer, input); assertThat(writer.getString()).isEqualTo("* LIST (\\HasChildren) NIL \"mailbox\"\r\n"); }
public static void encodeListingResponse(ImapCommand command, ImapResponseComposer composer, AbstractListingResponse response) throws IOException { composer.untagged(); composer.message(command.getName()); composer.openParen(); for (String attribute : getNameAttributes(response)) { composer.message(attribute); } composer.closeParen(); writeDelimiter(composer, response.getHierarchyDelimiter()); composer.mailbox(response.getName()); composer.end(); }
ListingEncodingUtils { public static void encodeListingResponse(ImapCommand command, ImapResponseComposer composer, AbstractListingResponse response) throws IOException { composer.untagged(); composer.message(command.getName()); composer.openParen(); for (String attribute : getNameAttributes(response)) { composer.message(attribute); } composer.closeParen(); writeDelimiter(composer, response.getHierarchyDelimiter()); composer.mailbox(response.getName()); composer.end(); } }
ListingEncodingUtils { public static void encodeListingResponse(ImapCommand command, ImapResponseComposer composer, AbstractListingResponse response) throws IOException { composer.untagged(); composer.message(command.getName()); composer.openParen(); for (String attribute : getNameAttributes(response)) { composer.message(attribute); } composer.closeParen(); writeDelimiter(composer, response.getHierarchyDelimiter()); composer.mailbox(response.getName()); composer.end(); }  }
ListingEncodingUtils { public static void encodeListingResponse(ImapCommand command, ImapResponseComposer composer, AbstractListingResponse response) throws IOException { composer.untagged(); composer.message(command.getName()); composer.openParen(); for (String attribute : getNameAttributes(response)) { composer.message(attribute); } composer.closeParen(); writeDelimiter(composer, response.getHierarchyDelimiter()); composer.mailbox(response.getName()); composer.end(); }  static void encodeListingResponse(ImapCommand command, ImapResponseComposer composer, AbstractListingResponse response); }
ListingEncodingUtils { public static void encodeListingResponse(ImapCommand command, ImapResponseComposer composer, AbstractListingResponse response) throws IOException { composer.untagged(); composer.message(command.getName()); composer.openParen(); for (String attribute : getNameAttributes(response)) { composer.message(attribute); } composer.closeParen(); writeDelimiter(composer, response.getHierarchyDelimiter()); composer.mailbox(response.getName()); composer.end(); }  static void encodeListingResponse(ImapCommand command, ImapResponseComposer composer, AbstractListingResponse response);  }