You can see the full document at
http://cvs.apache.org/viewcvs.cgi/james-server/src/java/org/apache/james
/transport/matchers/Attic/AbstractStorageQuota.java?rev=1.1.2.2&content-
type=text/vnd.viewcvs-markup
At the bottom look for:
...
/**
* Gets the storage used in the recipient's inbox.
*
* @param recipient the recipient to check
*/
protected long getUsed(MailAddress recipient, Mail _) throws
MessagingException {
long size = 0;
MailRepository userInbox =
mailServer.getUserInbox(recipient.getUser());
for (Iterator it = userInbox.list(); it.hasNext(); ) {
String key = (String) it.next();
MailImpl mc = userInbox.retrieve(key);
// Retrieve can return null if the mail is no longer in the
store.
if (mc != null) try {
size += mc.getMessageSize();
} catch (Throwable e) {
// MailRepository.retrieve() does NOT lock the message.
// It could be deleted while we're looping.
log("Exception in getting message size: " +
e.getMessage());
}
}
return size;
}
...
Hope this helps,
-JM
-----Original Message-----
From: Noel J. Bergman [mailto:[EMAIL PROTECTED]
Sent: 09 October 2003 17:58
To: James Developers List
Subject: RE: Return Messages
> I am working with James 2.1.3 and I don't seem to have the
> file AbstractStorageQuota in james.transport.matchers
See the CVS. It is simply an example, as is the POP3 Handler.
--- Noel
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]