YUI.add("pluginhost-base",function(i,s){var h=i.Lang;function t(){this._plugins={}}t.prototype={plug:function(i,s){var t,n,u;if(h.isArray(i))for(t=0,n=i.length;t<n;t++)this.plug(i[t]);else i&&!h.isFunction(i)&&(s=i.cfg,i=i.fn),i&&i.NS&&(u=i.NS,((s=s||{}).host=this).hasPlugin(u)?this[u].setAttrs&&this[u].setAttrs(s):(this[u]=new i(s),this._plugins[u]=i));return this},unplug:function(i){var s=i,t=this._plugins;if(i)(s=!h.isFunction(i)||!(s=i.NS)||t[s]&&t[s]===i?s:null)&&(this[s]&&(this[s].destroy&&this[s].destroy(),delete this[s]),t[s])&&delete t[s];else for(s in this._plugins)this._plugins.hasOwnProperty(s)&&this.unplug(s);return this},hasPlugin:function(i){return this._plugins[i]&&this[i]},_initPlugins:function(i){this._plugins=this._plugins||{},this._initConfigPlugins&&this._initConfigPlugins(i)},_destroyPlugins:function(){this.unplug()}},i.namespace("Plugin").Host=t},"patched-v3.18.7",{requires:["yui-base"]});