IntrospectionSupport to support overloaded setter methods
---------------------------------------------------------

                 Key: CAMEL-840
                 URL: https://issues.apache.org/activemq/browse/CAMEL-840
             Project: Apache Camel
          Issue Type: Improvement
          Components: camel-core
    Affects Versions: 1.5.0
            Reporter: Claus Ibsen


If you have overloaded setter methods for a given property Camel can only use 
the first found.

{code}
    private Expression expression;

    public void setExpression(Expression expression) {
        this.expression = expression;
    }

    public void setExpression(String fileLanguageExpression) {
        this.expression = FileLanguage.file(fileLanguageExpression);
    }
{code}

isn't supported. As Camel will try to convert the type before finding the 2nd 
setter method with the correct type.

Maybe the solution is to improve the code so it finds the String setter if the 
input is a string property instead of the Expression object, ie find the setter 
with a 100% match and use it, if not then fallback to type convertions.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to