On 8/10/07, Stefano Bagnara <[EMAIL PROTECTED]> wrote:
> Robert Burrell Donkin (JIRA) ha scritto:
> >     [ 
> > https://issues.apache.org/jira/browse/JSIEVE-6?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12518975
> >  ]
> >
> > Robert Burrell Donkin commented on JSIEVE-6:
> > --------------------------------------------
> >
> > There is also the design issue of where the address list parsing should be 
> > done.
> >
> > Adding a getAddresses(headerName) method to MailAdapter may allow the 
> > adapter to perform the parsing. The adapter may be able to optimise this or 
> > may be able to perform more intelligently parsing. However, this is at the 
> > cost of a wider API. Implementing in Address would have the advantage that 
> > it would only need to be done correctly in one place.
>
> I'm slightly on the MailAdapter.getAddresses side.
>
> If I understand it correctly this way we don't have to add the parsing
> to the jSieve core and we could use mime4j on the james adapter side to
> support this feature. (maybe this also means that it would be better to
> move the james adapter to the james server source tree ?)

this does seem best

MimeMessage contains address parsing code for the common headers. IMHO
it would be acceptable for implementations to offer a service limited
to common address headers anyway. the implementations in jsieve have
access to a MimeMessage representation. the JAMES version could offer
a more comprehensive service using Mime4J.

but what to do when the address cannot be parsed? i favour logging and
returning an empty list.

- robert

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to