No, the logging filters are not smart
enough to understand the relationships between classes. If you put logging for
a category in for a superclass, that’s it. Now what you can do is make
the logger protected and then have it assigned by the subclass. So the
subclass could assign it with its own value which would then get filtered out,
while a different class would leave it filtered in. That might be OK?
You set up flashlog by adding a mm.cfg
file to your windows %HOME% directory (usually c:\documents and
settings\<username>). In the mm.cfg you want:
ErrorReportingEnable=1
TraceOutputFileEnable=1
Matt
From:
[email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Michael Schmalle
Sent: Monday, March 06, 2006 5:58
PM
To: [email protected]
Subject: [flexcoders] Flex2 ::
mx.logging package usage IE TraceTarget.filters
Hello,
Now, I was experimenting with the mx.logging package. Looks really kewl, I have
got some things working(BTW the docs are completly messed up on method
signatures).
Any adobe peplz want to give a heads up on the filters property of ITarget aka
TraceTarget class?
I have this method...
protected function constructLogger():void
{
var
traceTarget:ITarget = new TraceTarget();
traceTarget.filters =
["com.teotigraphix.teodoc.core.TEODocObject"];
traceTarget.level =
LogEventLevel.DEBUG;
Log.addTarget(traceTarget);
__logger =
Log.getLogger("com.teotigraphix.teodoc.core.TEODocObject");
debug("constructLogger()");
}
Now, I am building a documenting framework for as3/mxml and most of my classes
inherit the TEODocObject for using services, logging and events. Now, using the
TraceTarget.filter, is there any way to filter calls FROM the TEODocObject and
filter out subclasses of certain packages ?
Example
com.teotigraphix.teodoc.core.Project extends
com.teotigraphix.teodoc.core.TEODocObject
I don't want the debug being called for this class Project
but I do want say
com.teotigraphix.teodoc.core.TEODocProjectManager extends
com.teotigraphix.teodoc.core.TEODocObject
Any way to do this?
Any more docs being produced for these classes?
Remember, I have been reading the spotty docs on this and most of my trips are
guesses ;-)
Also, how do I set up the flash trace.txt file ???
Peace, Mike
--
What goes up, does come down.
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
SPONSORED LINKS
YAHOO! GROUPS LINKS