Package org.apache.james.imap.message.response

Examples of org.apache.james.imap.message.response.ListResponse


                            with(equal("LIST")),
                            with(equal(Arrays.asList(values))),
                            with(equal('.')),
                            with(equal("INBOX.name")));
        }});
        encoder.encode(new ListResponse(false, false, true, false, false, false, "INBOX.name", '.'), composer, new FakeImapSession());
    }
View Full Code Here


                            with(equal("LIST")),
                            with(equal(Arrays.asList(values))),
                            with(equal('.')),
                            with(equal("INBOX.name")));
        }});
        encoder.encode(new ListResponse(false, false, false, true, false, false, "INBOX.name", '.'), composer, new FakeImapSession());
    }
View Full Code Here

    @Test
    public void testShouldAddHasChildrenToAttributes() throws Exception {
        // Setup
        attributesOutput.add("\\HasChildren");
        ListResponse input = new ListResponse(false, false, false, false, true, false, nameParameter, '.');
           
        // Exercise
        ListingEncodingUtils.encodeListingResponse(typeNameParameters, mock, input);
    }
View Full Code Here

   
    @Test
    public void testShouldAddHasNoChildrenToAttributes() throws Exception {
        // Setup
        attributesOutput.add("\\HasNoChildren");
        ListResponse input = new ListResponse(false, false, false, false, false, true, nameParameter, '.');
           
        // Exercise
        ListingEncodingUtils.encodeListingResponse(typeNameParameters, mock, input);
    }
View Full Code Here

        encoder = new LSubResponseEncoder(mockNextEncoder);
    }

    @Test
    public void testIsAcceptable() {
        assertFalse(encoder.isAcceptable(new ListResponse(true, true, true,
                true, false, false, "name", '.')));
        assertTrue(encoder.isAcceptable(new LSubResponse("name", true, '.')));
        assertFalse(encoder.isAcceptable(context.mock(ImapMessage.class)));
        assertFalse(encoder.isAcceptable(null));
    }
View Full Code Here

    }

    ListResponse createResponse(boolean noinferior, boolean noselect,
            boolean marked, boolean unmarked, boolean hasChildren,
            boolean hasNoChildren, char hierarchyDelimiter, String mailboxName) {
        return new ListResponse(noinferior, noselect, marked, unmarked,
                hasChildren, hasNoChildren, MailboxConstants.USER_NAMESPACE + MailboxConstants.DEFAULT_DELIMITER + mailboxName, hierarchyDelimiter);
    }
View Full Code Here

TOP

Related Classes of org.apache.james.imap.message.response.ListResponse

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.