Logger and trace

matej's Avatar


08 Jul, 2013 01:27 PM


I have some libraries that use native flash trace(). Is it possible to somehow output this trace into one of logger channels?
And is it possible to create new Logger channels?

I have CConsole https://code.google.com/p/flash-console/ and I am outputing each of logger channels into separate console channel.
It comes great for debugging on pepperFlash, also.

Now I wonder how can I send traces to flash-console also?

  1. Support Staff 1 Posted by creynders on 12 Jul, 2013 07:02 AM

    creynders's Avatar

    To reroute all logging to flash-console you'lle need to create an adapter that implements ILogTarget and add it as a logging target to the context:

    context. addLogTarget(new FlashConsoleLogTarget(context));

    If you want to provide channeled logging you'll need to mimic the extensions in extensions.enhancedLogging but with your own logger interface and implementations.

  2. 2 Posted by matej on 16 Jul, 2013 07:40 AM

    matej's Avatar

    Just to clarify :)
    will this make native trace() from other extensions also go to FlashConsole?

    I am allready routing all ILogger channels to console.

  3. Support Staff 3 Posted by creynders on 16 Jul, 2013 08:55 AM

    creynders's Avatar

    will this make native trace() from other extensions also go to FlashConsole?

    No, AFAIK that's impossible.

  4. Support Staff 4 Posted by Shaun Smith on 16 Jul, 2013 09:02 AM

    Shaun Smith's Avatar

    BTW, The extensions included in Robotlegs do not use native trace(), they all use the logger, so you can redirect their output at any time.

  5. 5 Posted by matej on 16 Jul, 2013 09:50 AM

    matej's Avatar

    yes ofcourse :)

    I am talking about external libraries.
    This doesnt have to do anything with robotlegs directly, I was wandering if there is a way to capture native trace, and then output the same one to robotlegs logger.

  6. Ondina D.F. closed this discussion on 17 Aug, 2013 10:52 AM.

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

Keyboard shortcuts


? 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