Closed undiwahn closed 3 years ago
did you want that to function the same as expand with all of the relevant params (source, context, etc.) or simply act as a method on the Expander that allows an object to be projected into another?
It should function identically to the existing expand in that respect. It wouldn't need a type hint, somewhat obviously, since the type hint is the type of the object passed in to overlay on to.
On Oct 24, 2017 5:51 PM, "alexbarbato" notifications@github.com wrote:
did you want that to function the same as expand with all of the relevant params (source, context, etc.) or simply act as a method on the Expander that allows an object to be projected into another
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/SkywardApps/popcorn/issues/30#issuecomment-339144285, or mute the thread https://github.com/notifications/unsubscribe-auth/AJNm3qS7iCScPp6h7tby0GudEV8x9qGyks5svlv4gaJpZM4QFH5T .
We want to create a variation of the expand method that, instead of trying to instantiate a new object to project into, takes an existing one.
This helps the scenario in which we have an existing item and we want to update it with items from the source object. So perhaps you have a Car and a projection that hides the license plate number:
I may want to get my existing car object, then overlay an EditableCar onto it to overwrite the values as set in EditableCar. So taking:
and expanding the following projection into it
would result in