Jan 30, 2009

Snipt.org is a nifty little tool for developers / everyone. It’s like twitpic but for code and long text. Punch in some code or a long paragraph, select the language type (“text” for long text), and then snip it! Snipt will give you a short URL to share your content with people via twitter.
Here’s my little snipt for you: http://snipt.org/63
Jan 22, 2009
Using the Flex 3 logging API is not really cut and dry. It is made to be rather extensible and flexible but at the same time it manages to be completely painful and hard to understand. The Log, ILogger, LogLogger, TraceTarget, LogEvent and LogEvent level classes and be rather cumbersome.
An example of a straight up ‘log write’ would be:
var mylog:ILogger = Log.getLogger("my.package.MyClassName");
if(Log.isDebug()){
mylog.debug("Hello from the logger");
}
This would get you [DEBUG] level output with the message “Hello from the logger”. The problem with this approach is that I wanted to be able to log from any class, without having to create ILogger instances in all classes. I also wanted the logging to be dynamic so I could hide the class package if I wanted, I also wanted the LogEvents to carry all the information that the actual ‘log write’ contained.
So I created CustomLogger and CustomLogEvent classes that are built on the pre-existing logging API. This simple goal of these classes is to make logging easier. Now you can directly call:
CustomLogger.debug("Hello from the custom_logger");
or you can access it with a Singleton instance:
var log:CustomLogger = CustomLogger.getInstance();
log.debug("Hello from the custom_logger");
So thats all good and well but how does this make things easier? By using the CustomLogger you now have FULL control over the log messages as opposed to handing them off to a Flex ILogger/LogLogger and letting it do what it will with the log messages. Also, you do not need to instantiate a new ILogger for every class that wants to write log output. Additionally the expanded CustomLogEvent class gives whatever is listening the full rundown on what is happening in terms of logging as opposed to just a glimpse.
Here is an example that shows how useful the new CustomLogger/CustomLogEvent classes are especially when it comes to directing log output to a different target (in this case, a List component).
(Either JavaScript is not active or you are using an old version of Adobe Flash Player. Please install the newest Flash Player.)
Apr 25, 2008

Hey blog fans! I have been MIA for a bit as I was at FITC2008! The conference was amazing, it’s really cool to see what other people are using new media for, and how the industry and the products that support it are advancing. I could ramble for hours about all the cool thing’s I saw but in a few words: Adobe Flash CS4 (Bones, true 2.5d, GPU-based shaders, advanced After-Effects style tween controls), AS4 (actionscript continues to mature), and lots of inspiration (Flight404).
But now I’m back in rochester, hammering away at school again. Actually I should say school is hammering away at me, FITC caused me to miss 4days of school, not that I really “missed” anything but I did fail to turn in 2 projects because of it. So now I have to bang out a Data Analysis I Minitab Exercise, finish my After Effects “slate”, animate and finish my “Earth Day” after effect piece, write a Query Letter for science writing, and finish an MVC framework for New Media Team Project. Ah and also continue to maintain TCBN, and do work to create some income. My life is dandy!
It’s all a huge pain in the ass but I’m working through it, updates are sure to follow as my time opens up. Some very cool thing’s I’m looking forward to posting about but for now I’ll just give my readers a sneak peak:
- TCBN Widget – That’s right, now if you blog is on TCBN it’s content will be published on sites around the world through the new TCBN widget. Some sites are already using it but the official public release is coming soon! All members will get their own unique API key and have the ability to tailor the widget to their liking!
- Some Cool School Projects – Hopefully my After Effects animations turn out looking cool, although we definitely aren’t given enough time to make anything amazing (see also: 10week quarters) but I’m doing my best to push it to be all it can be.
- AS3 Particle Engine – Inspired by Robert Hodgin and his work in processing, as well as the work of Joshua Davis I have decided to try and write an advanced particle engine in AS3. I am not usually one for these “creative” projects but these 2 really inspired me to try and apply my hardcore application programming knowledge to a completely different field. I am having to learn alot of math but I’m hoping the end result will be cool, updates will be posted regularly on this one
That’s all for now! Back to slugging away at school work, but keep your peepers open for updates some cool stuff should be coming over the next week.