Java Jackson annotation for changing field : <p>I have to call 3rd party API for currency exchange rate, but the JSON returned keep changing, if i request a <code>MYR</code> to <code>USD</code> conversion, it will return me: <code>{"MYR_USD":0.246731}</code>, so if i request for <code>KRW</code> to <code>USD</code>, it will return me <code>{"KRW_USD":0.000888}</code>.</p>

<p>I will have to map the returned result into pojo using <code>@JsonProperty</code>, is there any ways that works?</p>

<p>My current hard-coded workaround:</p>

<pre><code>@JsonIgnoreProperties(ignoreUnknown = true)
public class FreeCurrencyExchangeRate {

    @JsonProperty("MYR_USD")
    private double rate;

    public double getRate() {
        return rate;
    }

    public void setRate(double rate) {
        this.rate = rate;
    }
} 
</code></pre>
