Verbosity:
Filter:
Debug/Classes (extension) | Debugging

Verbosity
ExtensionExtension

managing levels of verbosity

Description

The Verbosity class allows you to manage different levels of verbosity easily.

Class Methods

.new

Create an instance of Verbosity

Arguments:

level

The current level of verbosity

key

The name or label of this instance of Verbosity

Returns:

an instance of Verbosity

.globalLevel

Get or set the global level of verbosity. This is added to the local level of verbosity of each instance of the class.

.target

The target for the verbosity posts to go to, this can be either the post window, a document, or a GUI window. The document or GUI window is created automatically.

Arguments:

nt

a Symbol, either \post for postwindow, \doc for a Document, or \win for a GUI Window.

Returns:

the Class

.timeStamp

Boolean to set whether or not to use a date and time stamp with each post.

.all

an IdentityDictionary of all instances of this class.

.makeGui

Create a graphical user interface to manage the verbosity levels of all instances of Verbosity, and the global level of Verbosity.

Returns:

a VerbosityAllGui

.doc

The Document or Window to which is posted (if not to the post window).

Returns:

a Document or Window

.post

posts to the Verbosity output. Used internally to make the actual posts.

Arguments:

string

the string to post

Instance Methods

.value

Post something at a certain verbosity level. This is the main method used when posting something.

Arguments:

lev

The level of verbosity equal or above which the string should be posted.

string

The string to be posted.

method

The methodname that calls the value method, this string is prepended to the string argument.

.key

The label of the instance

.level

The level of verbosity

.makeGui

Create a GUI window to manage the level of verbosity

.destroy

remove this instance of Verbosity from all instances.

Examples