You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-user@james.apache.org by Danny Angus <da...@thought.co.uk> on 2001/05/31 01:16:47 UTC

Ok, now what!

Ok, so I've written a new class to replace GenericListserve to suit myself
(re  the prefix thing) re-compiled everything using my new class, and _lo_
it works :-) (where do I get the cigar?)

Now my next question is.. where can I find out how to deal with MIME
messages in my mailet?

I thought I'd try adding a footer to messages, then I came up against MIME,
which I'm pretty cool with, but I don't want to re-invent the wheel, so my q
is what classes can I use to get at the parts of my message? are there some
in James, or another jakarta project, or do I need to source them elswhere?
(in which case I might write them after all)

d


---------------------------------------------------------------------
To unsubscribe, e-mail: james-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: james-user-help@jakarta.apache.org


Re: Ok, now what!

Posted by Harmeet <ha...@kodemuse.com>.
From: "Danny Angus" <da...@thought.co.uk>
> I thought I'd try adding a footer to messages, then I came up against
MIME,
> which I'm pretty cool with, but I don't want to re-invent the wheel, so my
q
> is what classes can I use to get at the parts of my message? are there
some
> in James, or another jakarta project, or do I need to source them
elswhere?
> (in which case I might write them after all)

I think you need the javax.mail package. The classes there can help you get
to your mail parts and modify them etc.

Harmeet
----- Original Message -----
From: "Danny Angus" <da...@thought.co.uk>
To: <ja...@jakarta.apache.org>
Sent: Wednesday, May 30, 2001 4:16 PM
Subject: Ok, now what!


> Ok, so I've written a new class to replace GenericListserve to suit myself
> (re  the prefix thing) re-compiled everything using my new class, and _lo_
> it works :-) (where do I get the cigar?)
>
> Now my next question is.. where can I find out how to deal with MIME
> messages in my mailet?
>
> I thought I'd try adding a footer to messages, then I came up against
MIME,
> which I'm pretty cool with, but I don't want to re-invent the wheel, so my
q
> is what classes can I use to get at the parts of my message? are there
some
> in James, or another jakarta project, or do I need to source them
elswhere?
> (in which case I might write them after all)
>
> d
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: james-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: james-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: james-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: james-user-help@jakarta.apache.org


Re: listserve, details, its all in the details

Posted by Harmeet <ha...@kodemuse.com>.
----- Original Message -----
From: "Danny Angus" <da...@thought.co.uk>
Subject: listserve, details, its all in the details


> I see this in GenericListserve:
>
> if (!isAttachmentsAllowed() && mail.getMessage().getContent() instanceof
> MimeMultipart) {
>                 getMailetContext().bounce(mail, "You cannot send
attachments
> to this listserv.");
>                 mail.setState(Mail.GHOST);
>                 return;


Not sure if this algorithm is correct to determine attachement. Multipart
Content may be a Multipart Mixed. Maybe there is a lurking bug there.

> where can I find out how to deal with MIME messages in my mailet?
javax.mail and javax.mail.internet would be good packages to look at. You
can get the source from Sun under SCSL license. It is part of J2EE source
distribution.

Harmeet


---------------------------------------------------------------------
To unsubscribe, e-mail: james-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: james-dev-help@jakarta.apache.org


listserve, details, its all in the details

Posted by Danny Angus <da...@thought.co.uk>.
I see this in GenericListserve:

if (!isAttachmentsAllowed() && mail.getMessage().getContent() instanceof
MimeMultipart) {
                getMailetContext().bounce(mail, "You cannot send attachments
to this listserv.");
                mail.setState(Mail.GHOST);
                return;



Does this mean that mime-type: multipart/alternative messages are canned
too? what if every part is disposition: inline, shouldn't they get through?

I asked this on the user list, but this is probably the better place:

where can I find out how to deal with MIME messages in my mailet?

I thought I'd try adding a footer to messages [in a mailet], then I came up
against MIME,
which I'm pretty cool with, but I don't want to re-invent the wheel, so my q
is what classes can I use to get at the parts of my message? are there some
in James, or another jakarta project, or do I need to source them elswhere?
(in which case I might write them after all, I've written a mime parser in
perl, it should get easier with practice!)


---------------------------------------------------------------------
To unsubscribe, e-mail: james-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: james-dev-help@jakarta.apache.org