class Money implements ValueObject {

    public static Money valueOf(Currency currency, Integer value) {
        if (currency == null || value == null) {
            return null;
        } else {
            return new Money(currency, value);
        }
    }

    @JsonCreator public  Money(@NonNull @JsonProperty("currency") Currency currency, @JsonProperty("amount") int amount);
    public  Money(@NonNull Currency currency, double amount);

}