}
private long appendMessage( String messageContent, MessageFlags flags,
Date datetime, ImapMailbox mailbox )
{
MimeMessageSource source =
new MimeMessageByteArraySource( "messageContent:" + System.currentTimeMillis(),
messageContent.getBytes());
MimeMessage message = new MimeMessageWrapper( source );
SimpleImapMessage imapMessage = mailbox.createMessage( message, flags, datetime );
return imapMessage.getUid();