Post Reply 
Author [OPEN]Optionality of interfaces?
AT core team member

Find all posts by this user
Quote this message in a reply
Default  26 November 2013 15:45
I might be controversial here: I'm wondering if it would be possible to get rid of the interfaces in AT, at least optionally?

IMO this is one of those concepts that is nice in theory but in practice it's a bit boring/tedious and with little gain in most of the cases.

From what Benoit told me, the reason they're in place now is the customization and sandboxing. So we can't completely get rid of them then. But we can at least try to make it less painful for the devs (hint: they don't like it, like any other boilerplate).

The first step could be to automagically create an ad-hoc interface for the controller which doesn't have the interface specified (for instance, iterate over public methods of the controller, i.e. ones not starting with an _underscore, and make all of them part of the interface). This gives a lightweight start for people who don't need this initially, and makes it possible to add it easily at a later point. I think this would be feasible and not so complex.

However what's another thing about the interfaces is that they're adding one more execution layer hence making stack traces more complex (especially painful when you're trying stepping into in a function call in the debugger and need to get step through all the fwk boilerplate). So it'd be great to have some kind of interface-less mode of execution - but I'm not sure if it'd be easy to do so without complicating the fwk code way too much.

Looking forward for the discussion.
(This post was last modified: 28 November 2013 07:21 by susanta.behera.)
Post Reply