SkywardApps / popcorn

Popcorn is a .Net Middleware for your RESTful API that allows your consumers to request exactly as much or as little as they need, with no effort from you.
https://skywardapps.github.io/popcorn/
MIT License
59 stars 19 forks source link

Add Sort ability to blind expansion #43

Closed alexbarbato closed 3 years ago

alexbarbato commented 6 years ago

Currently the sort function will not work at all for blindly expanded objects. The big question here is do we want to support sort (and thus likely other extensions + features we add to popcorn minus the simple include expansion) for Blindly expanded objects?

Possible Solution

Should we choose to extend the sort functionality to Blindly expanded objects, we will probably just try to sort objects normally (based on properties) and should that fail, attempt to sort blind based on dictionary values.

I could see this being a bit of a bear to keep up and possibly lead to some weird error scenarios if not implemented with some intention (just because doing things blind by nature makes them more risky)

(Side note: Reminder to update the tutorial when we update the sorting functionality as it currently says sorting isn't supported for blind expansion objects should we implement this)

alexbarbato commented 6 years ago

I can take this one if we decide it's something we'd like implemented.

undiwahn commented 6 years ago

I suggest we wait for the implementation of mapping dictionary -> concrete object to come through as I hope there will be some overlap.

On Nov 2, 2017 6:26 PM, "alexbarbato" notifications@github.com wrote:

I can take this one if we decide it's something we'd like implemented.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/SkywardApps/popcorn/issues/43#issuecomment-341576606, or mute the thread https://github.com/notifications/unsubscribe-auth/AJNm3u7v1uOE2Lc3t3hze2xiVN0l16Mvks5sykGmgaJpZM4QQbmB .