felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Leangen (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (FELIX-5561) Support for merging?
Date Wed, 22 Feb 2017 12:52:44 GMT

     [ https://issues.apache.org/jira/browse/FELIX-5561?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

David Leangen closed FELIX-5561.
    Assignee: David Leangen

> Support for merging?
> --------------------
>                 Key: FELIX-5561
>                 URL: https://issues.apache.org/jira/browse/FELIX-5561
>             Project: Felix
>          Issue Type: Wish
>          Components: Converter
>            Reporter: David Leangen
>            Assignee: David Leangen
> Would it be reasonable for the Converter to support a "merge" operation? Or is that just
too far out of scope.
> Example - merging a partial map into an existing object:
> Object o2 = converter.merge( m ).into( o1 ).
> Example of "complex" chaining operation - merging two maps, and converting to object:
> Object o2 = converter.merge( m1 ).into( m2 ).to( Object.class );
> Just thinking hypothetically for now.
> I can imagine cases where partial updates need to be applied. For instance, if a "Contact"
object exists, and we only want to update one or two fields, the Converter could assist:
> Contact updated = converter.merge( "{name:'Joe Smith', nickname:'joey'} ).into( contact
> If this is too far out of scope, I'll drop it here. Otherwise, I'll play around with
it a bit and let you know how that goes.
> wdyt?

This message was sent by Atlassian JIRA

View raw message