Return-Path: Delivered-To: apmail-james-mime4j-dev-archive@minotaur.apache.org Received: (qmail 30387 invoked from network); 27 Dec 2009 19:54:56 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 27 Dec 2009 19:54:56 -0000 Received: (qmail 98313 invoked by uid 500); 27 Dec 2009 19:54:56 -0000 Delivered-To: apmail-james-mime4j-dev-archive@james.apache.org Received: (qmail 98278 invoked by uid 500); 27 Dec 2009 19:54:56 -0000 Mailing-List: contact mime4j-dev-help@james.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: mime4j-dev@james.apache.org Delivered-To: mailing list mime4j-dev@james.apache.org Received: (qmail 98268 invoked by uid 99); 27 Dec 2009 19:54:56 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 27 Dec 2009 19:54:56 +0000 X-ASF-Spam-Status: No, hits=-10.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 27 Dec 2009 19:54:49 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 690B3234C045 for ; Sun, 27 Dec 2009 11:54:29 -0800 (PST) Message-ID: <375092592.1261943669415.JavaMail.jira@brutus.apache.org> Date: Sun, 27 Dec 2009 19:54:29 +0000 (UTC) From: "Stefano Bagnara (JIRA)" To: mime4j-dev@james.apache.org Subject: [jira] Resolved: (MIME4J-147) Move "default parsing" logic from AbstractField to DefaultFieldParser In-Reply-To: <1829904775.1261942649406.JavaMail.jira@brutus.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/MIME4J-147?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Stefano Bagnara resolved MIME4J-147. ------------------------------------ Resolution: Fixed Change applied. > Move "default parsing" logic from AbstractField to DefaultFieldParser > --------------------------------------------------------------------- > > Key: MIME4J-147 > URL: https://issues.apache.org/jira/browse/MIME4J-147 > Project: JAMES Mime4j > Issue Type: Improvement > Affects Versions: 0.6 > Reporter: Stefano Bagnara > Assignee: Stefano Bagnara > Priority: Critical > Fix For: 0.7 > > > As suggested in the ml we should move the default "delegation based" parsing logic from AbstractField to DefaultFieldParser. > This way we remove a lot of cycles in the code and the "default parsing" is exposed vua DefaultFieldParser instead of AbstractField (i never liked exposing a public feature via a static method of an abstract class). > here the ml message: > -- > AbstractField is the abstract class extended by each specific field > implementation. > AbstractField, at the same time, provide "static" access to a > DefaultFieldParser and provides static methods to get a > DefaultFieldParser and to parse a string into a field using that > default field parser. > So every field extend abstractField but AbstractField have a link to > every of its implementations via DefaultFieldParser => > DelegatingFieldParser. > This smells like a very bad idea. Is it me? > So, if you agree this should be improved here are 2 alternative solutions: > 1) the easy fix would be to move all of the static stuff from > AbstractField to DefaultFieldParser. As the methods are public static > methods this would introduce a backward compatibility issue. > -- -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.