1 <!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
4 <title>API: yahoo YAHOO (YUI Library)
</title>
5 <link rel=
"stylesheet" type=
"text/css" href=
"assets/api.css">
9 <div id=
"doc3" class=
"yui-t2">
12 <h1>Yahoo! UI Library
</h1>
13 <h3>YAHOO Global
<span class=
"subtitle">2.2.0</span></h3>
15 <a href=
"./index.html">Yahoo! UI Library
</a>
16 > <a href=
"./module_yahoo.html">yahoo
</a>
33 <span class=
"extends">
36 <span class=
"extends">
41 <!-- class tree goes here -->
46 <div class=
"summary description">
47 The YAHOO global namespace object. If YAHOO is already defined, the
48 existing YAHOO object will not be overwritten so that defined
49 namespaces are preserved.
55 <div class=
"section method details">
56 <h3><a name=
"methodDetails">Methods
</a></h3>
59 <a name=
"augment">augment
</a></h4>
66 <strong>augment
</strong>
84 <div class=
"description">
85 An alias for
<a href=
"YAHOO.lang.html#augment">YAHOO.lang.augment
</a>
88 <div class=
"description">
93 <code>r
<Function
></code>
94 the object to receive the augmentation
97 <code>s
<Function
></code>
98 the object that supplies the properties to augment
101 <code>arguments
<String*
></code>
102 zero or more properties methods to augment the
103 receiver with. If none specified, everything
104 in the supplier will be used unless it would
105 overwrite an existing property in the receiver
122 <a name=
"extend">extend
</a></h4>
129 <strong>extend
</strong>
147 <div class=
"description">
148 An alias for
<a href=
"YAHOO.lang.html#extend">YAHOO.lang.extend
</a>
151 <div class=
"description">
156 <code>subc
<Function
></code>
160 <code>superc
<Function
></code>
161 the object to inherit
164 <code>overrides
<Object
></code>
165 additional properties/methods to add to the
166 subclass prototype. These will override the
167 matching items obtained from the superclass
185 <a name=
"init">init
</a></h4>
192 <strong>init
</strong>
197 <div class=
"description">
198 Initializes the global by creating the default namespaces and applying
199 any new configuration information that is detected.
202 <div class=
"description">
218 <a name=
"log">log
</a></h4>
243 <div class=
"description">
244 Uses YAHOO.widget.Logger to output a log message, if the widget is
248 <div class=
"description">
253 <code>msg
<String
></code>
257 <code>cat
<String
></code>
258 The log category for the message. Default
259 categories are
"info",
"warn",
"error", time
".
260 Custom categories can be used as well. (opt)
263 <code>src <String></code>
264 The source of the the message (opt)
273 <dd>True if the log operation was successful.</dd>
281 <a name="namespace
">namespace</a></h4>
288 <strong>namespace</strong>
298 <div class="description
">
299 Returns the namespace specified and creates it if it doesn't exist
301 YAHOO.namespace("property.package
");
302 YAHOO.namespace("YAHOO.property.package
");
304 Either of the above would create YAHOO.property, then
305 YAHOO.property.package
306 Be careful when naming packages. Reserved words may work in some browsers
307 and not others. For instance, the following will fail in Safari:
309 YAHOO.namespace("really.long.nested.namespace
");
311 This fails because "long
" is a future reserved word in ECMAScript
314 <div class="description
">
319 <code>arguments <String*></code>
320 1-n namespaces to create
329 <dd>A reference to the last namespace object created</dd>
337 <a name="register
">register</a></h4>
344 <strong>register</strong>
362 <div class="description
">
363 Registers a module with the YAHOO object
366 <div class="description
">
371 <code>name <String></code>
372 the name of the module (event, slider, etc)
375 <code>mainClass <Function></code>
376 a reference to class in the module. This
377 class will be tagged with the version info
378 so that it will be possible to identify the
379 version that is in use when multiple versions
383 <code>data <Object></code>
384 metadata object for the module. Currently it
385 is expected to contain a "version
" property
386 and a "build
" property at minimum.
420 <li class=""><a href="module_animation.html
">animation</a></li>
422 <li class=""><a href="module_autocomplete.html
">autocomplete</a></li>
424 <li class=""><a href="module_button.html
">button</a></li>
426 <li class=""><a href="module_calendar.html
">calendar</a></li>
428 <li class=""><a href="module_connection.html
">connection</a></li>
430 <li class=""><a href="module_container.html
">container</a></li>
432 <li class=""><a href="module_datasource.html
">datasource</a></li>
434 <li class=""><a href="module_datatable.html
">datatable</a></li>
436 <li class=""><a href="module_dom.html
">dom</a></li>
438 <li class=""><a href="module_dragdrop.html
">dragdrop</a></li>
440 <li class=""><a href="module_element.html
">element</a></li>
442 <li class=""><a href="module_event.html
">event</a></li>
444 <li class=""><a href="module_history.html
">history</a></li>
446 <li class=""><a href="module_logger.html
">logger</a></li>
448 <li class=""><a href="module_menu.html
">menu</a></li>
450 <li class=""><a href="module_slider.html
">slider</a></li>
452 <li class=""><a href="module_tabview.html
">tabview</a></li>
454 <li class=""><a href="module_treeview.html
">treeview</a></li>
456 <li class="selected
"><a href="module_yahoo.html
">yahoo</a></li>
463 <li class="selected
"><a href="YAHOO.html
">YAHOO</a></li>
464 <li class=""><a href="YAHOO.env.html
">YAHOO.env</a></li>
465 <li class=""><a href="YAHOO.lang.html
">YAHOO.lang</a></li>
466 <li class=""><a href="YAHOO_config.html
">YAHOO_config</a></li>
473 <li class=""><a href="YAHOO.js.html
">YAHOO.js</a></li>
481 <li><!--<code>void</code>-->
482 <a href="#augment
">augment</a>
484 <li><!--<code>void</code>-->
485 <a href="#extend
">extend</a>
487 <li><!--<code>void</code>-->
488 <a href="#init
">init</a>
490 <li><!--<code>Boolean</code>-->
491 <a href="#log
">log</a>
493 <li><!--<code>Object</code>-->
494 <a href="#namespace
">namespace</a>
496 <li><!--<code>void</code>-->
497 <a href="#register
">register</a>
509 Copyright © 2007 Yahoo! Inc. All rights reserved.