Prev | Current Page 347 | Next

L. McColl-Sylvester and F. Ponticelli

"Professional haXe and Neko"

This saves loads of time in decorating your
trace calls yourself so that you can tell one trace from another. Another great feature is being able to
reroute the trace output, so you can stream it to an external file or GUI container. You can even choose
to rewrite the functionality of the trace function altogether, if you like. Also, unlike the pesky Flash
version of the trace function, when you pass an object to a haXe trace , it will iterate through each
property of the object and attempt to convert the property ??™ s value to a string representation; then, if any
nested objects are found, it will break these up, also. This makes your output so much more usable than
the useless [Object Object] trace.
The haxe.Log Class
The haXe trace function is actually a simple wrapper for lower level functions supported by each
platform. There is also a second static version of the higher level trace function belonging to the haxe
.Log class that provides a gateway to this functionality. The difference here is that the haxe.


Pages:
335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359