Custom Processors a la Swiz

ndcollins's Avatar

ndcollins

09 Jun, 2010 04:07 PM

The ability to relatively easily create custom processors is, in my opinion, one of the killer features of Swiz and I would love to see this kind of functionality ported into RobotLegs. Has anyone made any efforts in this area?

  1. Support Staff 1 Posted by Joel Hooks on 09 Jun, 2010 04:27 PM

    Joel Hooks's Avatar

    I am so prejudiced against adding additional metadata. Metadata in AS3 is awful. It relies on magical string configuration, hides real work, and there is no IDE support for it in any significant form (SourceMate helps a bit). The concept of people arbitrarily pasting custom meta around an app in AS3 disturbs me to my nerd core.

    As a consultant who specializes in unraveling the twisted mazes of people's jacked up code, I love the idea.

    Short answer is no, there hasn't been any work in that regard. The "easiest" approach would likely be to bundle up a Swiz adapter as a replacement for SwiftSuspenders.

  2. 2 Posted by Stray on 09 Jun, 2010 04:53 PM

    Stray's Avatar

    I'm with Joel on this one.

    The benefit of Robotlegs as I experience it is that you can very quickly get an idea of the core workings of an app just by inspecting the context. Doing a project-wide search for [Inject] also gives you some clarity very quickly.

    Metadata in the AS3 compiler is hard to debug.

    Try this

    [Inject];
    public var somethingToInject:SomethingToInject

    just the presence of the ; after the [Inject] kills the metadata.

    The compiler won't give you an error. (At least the flex 4 SDK compiler doesn't give me one).

    I'm sure I could attempt some gnarly regex search to find all metadata tags without picking up array style assignments, but custom metadata sounds to me like a piece of rope just long enough to really hang yourself.

  3. Support Staff 3 Posted by Joel Hooks on 09 Jun, 2010 05:00 PM

    Joel Hooks's Avatar

    custom metadata sounds to me like a piece of rope just long enough to really hang yourself.

    Which is why it is so attractive to somebody that bills by the hour ;0

  4. Stray closed this discussion on 16 Feb, 2011 04:51 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac