camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <>
Subject [jira] [Commented] (CAMEL-9954) FormatFactory should be real Factory-pattern
Date Sat, 21 May 2016 07:56:14 GMT


ASF GitHub Bot commented on CAMEL-9954:

GitHub user anoordover opened a pull request:

    Camel 9954

    Pull request for CAMEL-9954

You can merge this pull request into a Git repository by running:

    $ git pull CAMEL-9954

Alternatively you can review and apply these changes as the patch at:

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #990
commit 69f7192633801f1d46cd06b2cff3b4ea3651d59c
Author: Arno Noordover <>
Date:   2016-05-08T09:46:17Z

    CAMEL-9954: FormatFactory should be real Factory-pattern

commit 97957c744ac76144ccfd963f607a0171397cc5d1
Author: Arno Noordover <>
Date:   2016-05-20T21:10:32Z

    CAMEL-9954: OSGi ready, FactoryRegistry via Registry, Annotation for class to provide
additional factories


> FormatFactory should be real Factory-pattern
> --------------------------------------------
>                 Key: CAMEL-9954
>                 URL:
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-bindy
>            Reporter: Arno Noordover
>            Priority: Minor
>             Fix For: 2.18.0
>         Attachments: CAMEL_9954Patch2.patch, CAMEL_9954__FormatFactory_should_be_real_Factory_pattern.patch
>   Original Estimate: 48h
>  Remaining Estimate: 48h
> The class org.apache.camel.dataformat.bindy.FormatFactory is a utility class which supports
a factory-pattern.
> According to the factory-pattern this should not be a utility-class but it should be
a class that can be instantiated.
> This class should implement an interface or extend an abstract class.
> Maybe we should make a factory per Format and choose amongst the following solutions:
> * let each formatter answer the question about being able to format for certain formating-options
(based on type and optionally the pattern for all "numeric" format factories);
> * put all formatters in a hashmap with the type as a key.
> With this last solution all the "numeric" format factory should decide which format to
return (e.g. BytePatternFormat or ByteFormat based on the pattern being empty or not)

This message was sent by Atlassian JIRA

View raw message