text: if (typeof __coverage__ === 'undefined') { __coverage__ = {}; }
  if (!__coverage__['build/view/view.js']) {
     __coverage__['build/view/view.js'] = {"path":"build/view/view.js","s":{"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0},"b":{"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0,0],"7":[0,0],"8":[0,0],"9":[0,0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0,0],"14":[0,0],"15":[0,0],"16":[0,0],"17":[0,0]},"f":{"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0},"fnMap":{"1":{"name":"(anonymous_1)","line":1,"loc":{"start":{"line":1,"column":16},"end":{"line":1,"column":35}}},"2":{"name":"View","line":35,"loc":{"start":{"line":35,"column":0},"end":{"line":35,"column":16}}},"3":{"name":"(anonymous_3)","line":128,"loc":{"start":{"line":128,"column":17},"end":{"line":128,"column":35}}},"4":{"name":"(anonymous_4)","line":161,"loc":{"start":{"line":161,"column":13},"end":{"line":161,"column":32}}},"5":{"name":"(anonymous_5)","line":168,"loc":{"start":{"line":168,"column":38},"end":{"line":168,"column":50}}},"6":{"name":"(anonymous_6)","line":176,"loc":{"start":{"line":176,"column":16},"end":{"line":176,"column":28}}},"7":{"name":"(anonymous_7)","line":197,"loc":{"start":{"line":197,"column":18},"end":{"line":197,"column":36}}},"8":{"name":"(anonymous_8)","line":249,"loc":{"start":{"line":249,"column":12},"end":{"line":249,"column":33}}},"9":{"name":"(anonymous_9)","line":262,"loc":{"start":{"line":262,"column":18},"end":{"line":262,"column":30}}},"10":{"name":"(anonymous_10)","line":263,"loc":{"start":{"line":263,"column":47},"end":{"line":263,"column":65}}},"11":{"name":"(anonymous_11)","line":280,"loc":{"start":{"line":280,"column":12},"end":{"line":280,"column":24}}},"12":{"name":"(anonymous_12)","line":307,"loc":{"start":{"line":307,"column":12},"end":{"line":307,"column":24}}},"13":{"name":"(anonymous_13)","line":319,"loc":{"start":{"line":319,"column":23},"end":{"line":319,"column":35}}},"14":{"name":"(anonymous_14)","line":333,"loc":{"start":{"line":333,"column":19},"end":{"line":333,"column":36}}},"15":{"name":"(anonymous_15)","line":370,"loc":{"start":{"line":370,"column":27},"end":{"line":370,"column":39}}}},"statementMap":{"1":{"start":{"line":1,"column":0},"end":{"line":433,"column":69}},"2":{"start":{"line":35,"column":0},"end":{"line":37,"column":1}},"3":{"start":{"line":36,"column":4},"end":{"line":36,"column":55}},"4":{"start":{"line":39,"column":0},"end":{"line":429,"column":3}},"5":{"start":{"line":129,"column":8},"end":{"line":129,"column":32}},"6":{"start":{"line":132,"column":8},"end":{"line":133,"column":64}},"7":{"start":{"line":135,"column":8},"end":{"line":135,"column":61}},"8":{"start":{"line":138,"column":8},"end":{"line":139,"column":24}},"9":{"start":{"line":145,"column":8},"end":{"line":145,"column":66}},"10":{"start":{"line":163,"column":8},"end":{"line":171,"column":9}},"11":{"start":{"line":168,"column":12},"end":{"line":170,"column":15}},"12":{"start":{"line":169,"column":16},"end":{"line":169,"column":41}},"13":{"start":{"line":173,"column":8},"end":{"line":173,"column":50}},"14":{"start":{"line":177,"column":8},"end":{"line":177,"column":28}},"15":{"start":{"line":178,"column":8},"end":{"line":178,"column":31}},"16":{"start":{"line":198,"column":8},"end":{"line":200,"column":46}},"17":{"start":{"line":202,"column":8},"end":{"line":202,"column":28}},"18":{"start":{"line":204,"column":8},"end":{"line":204,"column":41}},"19":{"start":{"line":206,"column":8},"end":{"line":229,"column":9}},"20":{"start":{"line":207,"column":12},"end":{"line":207,"column":54}},"21":{"start":{"line":207,"column":43},"end":{"line":207,"column":52}},"22":{"start":{"line":209,"column":12},"end":{"line":209,"column":40}},"23":{"start":{"line":211,"column":12},"end":{"line":228,"column":13}},"24":{"start":{"line":212,"column":16},"end":{"line":212,"column":56}},"25":{"start":{"line":212,"column":45},"end":{"line":212,"column":54}},"26":{"start":{"line":214,"column":16},"end":{"line":214,"column":41}},"27":{"start":{"line":218,"column":16},"end":{"line":220,"column":17}},"28":{"start":{"line":219,"column":20},"end":{"line":219,"column":44}},"29":{"start":{"line":222,"column":16},"end":{"line":224,"column":17}},"30":{"start":{"line":223,"column":20},"end":{"line":223,"column":29}},"31":{"start":{"line":226,"column":16},"end":{"line":227,"column":71}},"32":{"start":{"line":231,"column":8},"end":{"line":231,"column":20}},"33":{"start":{"line":250,"column":8},"end":{"line":251,"column":54}},"34":{"start":{"line":263,"column":8},"end":{"line":267,"column":11}},"35":{"start":{"line":264,"column":12},"end":{"line":266,"column":13}},"36":{"start":{"line":265,"column":16},"end":{"line":265,"column":32}},"37":{"start":{"line":269,"column":8},"end":{"line":269,"column":38}},"38":{"start":{"line":270,"column":8},"end":{"line":270,"column":20}},"39":{"start":{"line":281,"column":8},"end":{"line":281,"column":46}},"40":{"start":{"line":282,"column":8},"end":{"line":282,"column":40}},"41":{"start":{"line":283,"column":8},"end":{"line":283,"column":20}},"42":{"start":{"line":308,"column":8},"end":{"line":308,"column":20}},"43":{"start":{"line":320,"column":8},"end":{"line":320,"column":46}},"44":{"start":{"line":321,"column":8},"end":{"line":321,"column":44}},"45":{"start":{"line":338,"column":8},"end":{"line":351,"column":9}},"46":{"start":{"line":339,"column":12},"end":{"line":350,"column":13}},"47":{"start":{"line":342,"column":16},"end":{"line":342,"column":40}},"48":{"start":{"line":343,"column":16},"end":{"line":343,"column":36}},"49":{"start":{"line":348,"column":16},"end":{"line":348,"column":56}},"50":{"start":{"line":349,"column":16},"end":{"line":349,"column":46}},"51":{"start":{"line":353,"column":8},"end":{"line":353,"column":21}},"52":{"start":{"line":371,"column":8},"end":{"line":371,"column":39}}},"branchMap":{"1":{"line":129,"type":"binary-expr","locations":[{"start":{"line":129,"column":8},"end":{"line":129,"column":14}},{"start":{"line":129,"column":19},"end":{"line":129,"column":30}}]},"2":{"line":132,"type":"binary-expr","locations":[{"start":{"line":132,"column":8},"end":{"line":132,"column":32}},{"start":{"line":133,"column":13},"end":{"line":133,"column":62}}]},"3":{"line":135,"type":"binary-expr","locations":[{"start":{"line":135,"column":8},"end":{"line":135,"column":23}},{"start":{"line":135,"column":28},"end":{"line":135,"column":59}}]},"4":{"line":138,"type":"cond-expr","locations":[{"start":{"line":138,"column":38},"end":{"line":138,"column":73}},{"start":{"line":139,"column":12},"end":{"line":139,"column":23}}]},"5":{"line":163,"type":"if","locations":[{"start":{"line":163,"column":8},"end":{"line":163,"column":8}},{"start":{"line":163,"column":8},"end":{"line":163,"column":8}}]},"6":{"line":163,"type":"binary-expr","locations":[{"start":{"line":163,"column":12},"end":{"line":163,"column":19}},{"start":{"line":163,"column":24},"end":{"line":163,"column":38}},{"start":{"line":163,"column":42},"end":{"line":163,"column":59}}]},"7":{"line":204,"type":"binary-expr","locations":[{"start":{"line":204,"column":8},"end":{"line":204,"column":14}},{"start":{"line":204,"column":19},"end":{"line":204,"column":39}}]},"8":{"line":207,"type":"if","locations":[{"start":{"line":207,"column":12},"end":{"line":207,"column":12}},{"start":{"line":207,"column":12},"end":{"line":207,"column":12}}]},"9":{"line":212,"type":"if","locations":[{"start":{"line":212,"column":16},"end":{"line":212,"column":16}},{"start":{"line":212,"column":16},"end":{"line":212,"column":16}}]},"10":{"line":218,"type":"if","locations":[{"start":{"line":218,"column":16},"end":{"line":218,"column":16}},{"start":{"line":218,"column":16},"end":{"line":218,"column":16}}]},"11":{"line":222,"type":"if","locations":[{"start":{"line":222,"column":16},"end":{"line":222,"column":16}},{"start":{"line":222,"column":16},"end":{"line":222,"column":16}}]},"12":{"line":250,"type":"cond-expr","locations":[{"start":{"line":250,"column":27},"end":{"line":250,"column":43}},{"start":{"line":251,"column":16},"end":{"line":251,"column":53}}]},"13":{"line":264,"type":"if","locations":[{"start":{"line":264,"column":12},"end":{"line":264,"column":12}},{"start":{"line":264,"column":12},"end":{"line":264,"column":12}}]},"14":{"line":282,"type":"binary-expr","locations":[{"start":{"line":282,"column":8},"end":{"line":282,"column":17}},{"start":{"line":282,"column":21},"end":{"line":282,"column":39}}]},"15":{"line":321,"type":"binary-expr","locations":[{"start":{"line":321,"column":8},"end":{"line":321,"column":17}},{"start":{"line":321,"column":21},"end":{"line":321,"column":43}}]},"16":{"line":338,"type":"if","locations":[{"start":{"line":338,"column":8},"end":{"line":338,"column":8}},{"start":{"line":338,"column":8},"end":{"line":338,"column":8}}]},"17":{"line":339,"type":"if","locations":[{"start":{"line":339,"column":12},"end":{"line":339,"column":12}},{"start":{"line":339,"column":12},"end":{"line":339,"column":12}}]}},"code":["(function () { YUI.add('view', function (Y, NAME) {","","/**","Represents a logical piece of an application's user interface, and provides a","lightweight, overridable API for rendering content and handling delegated DOM","events on a container element.","","@module app","@submodule view","@since 3.4.0","**/","","/**","Represents a logical piece of an application's user interface, and provides a","lightweight, overridable API for rendering content and handling delegated DOM","events on a container element.","","The View class imposes little structure and provides only minimal functionality","of its own: it's basically just an overridable API interface that helps you","implement custom views.","","As of YUI 3.5.0, View allows ad-hoc attributes to be specified at instantiation","time, so you don't need to subclass `Y.View` to add custom attributes. Just pass","them to the constructor:","","    var view = new Y.View({foo: 'bar'});","    view.get('foo'); // => \"bar\"","","@class View","@constructor","@extends Base","@since 3.4.0","**/","","function View() {","    View.superclass.constructor.apply(this, arguments);","}","","Y.View = Y.extend(View, Y.Base, {","    // -- Public Properties ----------------------------------------------------","","    /**","    Template for this view's container.","","    @property containerTemplate","    @type String","    @default \"<div/>\"","    @since 3.5.0","    **/","    containerTemplate: '<div/>',","","    /**","    Hash of CSS selectors mapped to events to delegate to elements matching","    those selectors.","","    CSS selectors are relative to the `container` element. Events are attached","    to the container, and delegation is used so that subscribers are only","    notified of events that occur on elements inside the container that match","    the specified selectors. This allows the container's contents to be re-","    rendered as needed without losing event subscriptions.","","    Event handlers can be specified either as functions or as strings that map","    to function names on this view instance or its prototype.","","    The `this` object in event handlers will refer to this view instance. If","    you'd prefer `this` to be something else, use `Y.bind()` to bind a custom","    `this` object.","","    @example","","        var view = new Y.View({","            events: {","                // Call `this.toggle()` whenever the element with the id","                // \"toggle-button\" is clicked.","                '#toggle-button': {click: 'toggle'},","","                // Call `this.hoverOn()` when the mouse moves over any element","                // with the \"hoverable\" class, and `this.hoverOff()` when the","                // mouse moves out of any element with the \"hoverable\" class.","                '.hoverable': {","                    mouseover: 'hoverOn',","                    mouseout : 'hoverOff'","                }","            }","        });","","    @property events","    @type Object","    @default {}","    **/","    events: {},","","    /**","    Template for this view's contents.","","    This is a convenience property that has no default behavior of its own.","    It's only provided as a convention to allow you to store whatever you","    consider to be a template, whether that's an HTML string, a `Y.Node`","    instance, a Mustache template, or anything else your little heart","    desires.","","    How this template gets used is entirely up to you and your custom","    `render()` method.","","    @property template","    @type mixed","    @default ''","    **/","    template: '',","","    // -- Protected Properties -------------------------------------------------","","    /**","    This tells `Y.Base` that it should create ad-hoc attributes for config","    properties passed to View's constructor. This makes it possible to","    instantiate a view and set a bunch of attributes without having to subclass","    `Y.View` and declare all those attributes first.","","    @property _allowAdHocAttrs","    @type Boolean","    @default true","    @protected","    @since 3.5.0","    **/","    _allowAdHocAttrs: true,","","    // -- Lifecycle Methods ----------------------------------------------------","    initializer: function (config) {","        config || (config = {});","","        // Set instance properties specified in the config.","        config.containerTemplate &&","            (this.containerTemplate = config.containerTemplate);","","        config.template && (this.template = config.template);","","        // Merge events from the config into events in `this.events`.","        this.events = config.events ? Y.merge(this.events, config.events) :","            this.events;","","        // When the container node changes (or when it's set for the first","        // time), we'll attach events to it, but not until then. This allows the","        // container to be created lazily the first time it's accessed rather","        // than always on init.","        this.after('containerChange', this._afterContainerChange);","    },","","    /**","    Destroys this View, detaching any DOM events and optionally also destroying","    its container node.","","    By default, the container node will not be destroyed. Pass an _options_","    object with a truthy `remove` property to destroy the container as well.","","    @method destroy","    @param {Object} [options] Options.","        @param {Boolean} [options.remove=false] If `true`, this View's container","            will be removed from the DOM and destroyed as well.","    @chainable","    */","    destroy: function (options) {","        // We also accept `delete` as a synonym for `remove`.","        if (options && (options.remove || options['delete'])) {","            // Attaching an event handler here because the `destroy` event is","            // preventable. If we destroyed the container before calling the","            // superclass's `destroy()` method and the event was prevented, the","            // class would end up in a broken state.","            this.onceAfter('destroy', function () {","                this._destroyContainer();","            });","        }","","        return View.superclass.destroy.call(this);","    },","","    destructor: function () {","        this.detachEvents();","        delete this._container;","    },","","    // -- Public Methods -------------------------------------------------------","","    /**","    Attaches delegated event handlers to this view's container element. This","    method is called internally to subscribe to events configured in the","    `events` attribute when the view is initialized.","","    You may override this method to customize the event attaching logic.","","    @method attachEvents","    @param {Object} [events] Hash of events to attach. See the docs for the","        `events` attribute for details on the format. If not specified, this","        view's `events` property will be used.","    @chainable","    @see detachEvents","    **/","    attachEvents: function (events) {","        var container = this.get('container'),","            owns      = Y.Object.owns,","            handler, handlers, name, selector;","","        this.detachEvents();","","        events || (events = this.events);","","        for (selector in events) {","            if (!owns(events, selector)) { continue; }","","            handlers = events[selector];","","            for (name in handlers) {","                if (!owns(handlers, name)) { continue; }","","                handler = handlers[name];","","                // TODO: Make this more robust by using lazy-binding:","                // `handler = Y.bind(handler, this);`","                if (typeof handler === 'string') {","                    handler = this[handler];","                }","","                if (!handler) {","                    continue;","                }","","                this._attachedViewEvents.push(","                    container.delegate(name, handler, selector, this));","            }","        }","","        return this;","    },","","    /**","    Creates and returns a container node for this view.","","    By default, the container is created from the HTML template specified in the","    `containerTemplate` property, and is _not_ added to the DOM automatically.","","    You may override this method to customize how the container node is created","    (such as by rendering it from a custom template format). Your method must","    return a `Y.Node` instance.","","    @method create","    @param {HTMLElement|Node|String} [container] Selector string, `Y.Node`","        instance, or DOM element to use at the container node.","    @return {Node} Node instance of the created container node.","    **/","    create: function (container) {","        return container ? Y.one(container) :","                Y.Node.create(this.containerTemplate);","    },","","    /**","    Detaches DOM events that have previously been attached to the container by","    `attachEvents()`.","","    @method detachEvents","    @chainable","    @see attachEvents","    **/","    detachEvents: function () {","        Y.Array.each(this._attachedViewEvents, function (handle) {","            if (handle) {","                handle.detach();","            }","        });","","        this._attachedViewEvents = [];","        return this;","    },","","    /**","    Removes this view's container element from the DOM (if it's in the DOM),","    but doesn't destroy it or any event listeners attached to it.","","    @method remove","    @chainable","    **/","    remove: function () {","        var container = this.get('container');","        container && container.remove();","        return this;","    },","","    /**","    Renders this view.","","    This method is a noop by default. Override it to provide a custom","    implementation that renders this view's content and appends it to the","    container element. Ideally your `render` method should also return `this` as","    the end to allow chaining, but that's up to you.","","    Since there's no default renderer, you're free to render your view however","    you see fit, whether that means manipulating the DOM directly, dumping","    strings into `innerHTML`, or using a template language of some kind.","","    For basic templating needs, `Y.Node.create()` and `Y.Lang.sub()` may","    suffice, but there are no restrictions on what tools or techniques you can","    use to render your view. All you need to do is append something to the","    container element at some point, and optionally append the container","    to the DOM if it's not there already.","","    @method render","    @chainable","    **/","    render: function () {","        return this;","    },","","    // -- Protected Methods ----------------------------------------------------","","    /**","    Removes the `container` from the DOM and purges all its event listeners.","","    @method _destroyContainer","    @protected","    **/","    _destroyContainer: function () {","        var container = this.get('container');","        container && container.remove(true);","    },","","    /**","    Getter for the `container` attribute.","","    @method _getContainer","    @param {Node|null} value Current attribute value.","    @return {Node} Container node.","    @protected","    @since 3.5.0","    **/","    _getContainer: function (value) {","        // This wackiness is necessary to enable fully lazy creation of the","        // container node both when no container is specified and when one is","        // specified via a valueFn.","","        if (!this._container) {","            if (value) {","                // Attach events to the container when it's specified via a","                // valueFn, which won't fire the containerChange event.","                this._container = value;","                this.attachEvents();","            } else {","                // Create a default container and set that as the new attribute","                // value. The `this._container` property prevents infinite","                // recursion.","                value = this._container = this.create();","                this._set('container', value);","            }","        }","","        return value;","    },","","    // -- Protected Event Handlers ---------------------------------------------","","    /**","    Handles `containerChange` events. Detaches event handlers from the old","    container (if any) and attaches them to the new container.","","    Right now the `container` attr is initOnly so this event should only ever","    fire the first time the container is created, but in the future (once Y.App","    can handle it) we may allow runtime container changes.","","    @method _afterContainerChange","    @protected","    @since 3.5.0","    **/","    _afterContainerChange: function () {","        this.attachEvents(this.events);","    }","}, {","    NAME: 'view',","","    ATTRS: {","        /**","        Container node into which this view's content will be rendered.","","        The container node serves as the host for all DOM events attached by the","        view. Delegation is used to handle events on children of the container,","        allowing the container's contents to be re-rendered at any time without","        losing event subscriptions.","","        The default container is a `<div>` Node, but you can override this in","        a subclass, or by passing in a custom `container` config value at","        instantiation time. If you override the default container in a subclass","        using `ATTRS`, you must use the `valueFn` property. The view's constructor","        will ignore any assignments using `value`.","","        When `container` is overridden by a subclass or passed as a config","        option at instantiation time, you can provide it as a selector string, a","        DOM element, a `Y.Node` instance, or (if you are subclassing and modifying","        the attribute), a `valueFn` function that returns a `Y.Node` instance.","        The value will be converted into a `Y.Node` instance if it isn't one","        already.","","        The container is not added to the page automatically. This allows you to","        have full control over how and when your view is actually rendered to","        the page.","","        @attribute container","        @type HTMLElement|Node|String","        @default Y.Node.create(this.containerTemplate)","        @writeOnce","        **/","        container: {","            getter   : '_getContainer',","            setter   : Y.one,","            writeOnce: true","        }","    },","","    /**","    Properties that shouldn't be turned into ad-hoc attributes when passed to","    View's constructor.","","    @property _NON_ATTRS_CFG","    @type Array","    @static","    @protected","    @since 3.5.0","    **/","    _NON_ATTRS_CFG: [","        'containerTemplate',","        'events',","        'template'","    ]","});","","","","}, 'patched-v3.18.0', {\"requires\": [\"base-build\", \"node-event-delegate\"]});","","}());"]};
  }
  var __cov_WKkurTqscWZwqGjHXZ6avQ = __coverage__['build/view/view.js'];
  __cov_WKkurTqscWZwqGjHXZ6avQ.s['1']++;YUI.add('view',function(Y,NAME){__cov_WKkurTqscWZwqGjHXZ6avQ.f['1']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['2']++;function View(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['2']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['3']++;View.superclass.constructor.apply(this,arguments);}__cov_WKkurTqscWZwqGjHXZ6avQ.s['4']++;Y.View=Y.extend(View,Y.Base,{containerTemplate:'<div/>',events:{},template:'',_allowAdHocAttrs:true,initializer:function(config){__cov_WKkurTqscWZwqGjHXZ6avQ.f['3']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['5']++;(__cov_WKkurTqscWZwqGjHXZ6avQ.b['1'][0]++,config)||(__cov_WKkurTqscWZwqGjHXZ6avQ.b['1'][1]++,config={});__cov_WKkurTqscWZwqGjHXZ6avQ.s['6']++;(__cov_WKkurTqscWZwqGjHXZ6avQ.b['2'][0]++,config.containerTemplate)&&(__cov_WKkurTqscWZwqGjHXZ6avQ.b['2'][1]++,this.containerTemplate=config.containerTemplate);__cov_WKkurTqscWZwqGjHXZ6avQ.s['7']++;(__cov_WKkurTqscWZwqGjHXZ6avQ.b['3'][0]++,config.template)&&(__cov_WKkurTqscWZwqGjHXZ6avQ.b['3'][1]++,this.template=config.template);__cov_WKkurTqscWZwqGjHXZ6avQ.s['8']++;this.events=config.events?(__cov_WKkurTqscWZwqGjHXZ6avQ.b['4'][0]++,Y.merge(this.events,config.events)):(__cov_WKkurTqscWZwqGjHXZ6avQ.b['4'][1]++,this.events);__cov_WKkurTqscWZwqGjHXZ6avQ.s['9']++;this.after('containerChange',this._afterContainerChange);},destroy:function(options){__cov_WKkurTqscWZwqGjHXZ6avQ.f['4']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['10']++;if((__cov_WKkurTqscWZwqGjHXZ6avQ.b['6'][0]++,options)&&((__cov_WKkurTqscWZwqGjHXZ6avQ.b['6'][1]++,options.remove)||(__cov_WKkurTqscWZwqGjHXZ6avQ.b['6'][2]++,options['delete']))){__cov_WKkurTqscWZwqGjHXZ6avQ.b['5'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['11']++;this.onceAfter('destroy',function(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['5']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['12']++;this._destroyContainer();});}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['5'][1]++;}__cov_WKkurTqscWZwqGjHXZ6avQ.s['13']++;return View.superclass.destroy.call(this);},destructor:function(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['6']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['14']++;this.detachEvents();__cov_WKkurTqscWZwqGjHXZ6avQ.s['15']++;delete this._container;},attachEvents:function(events){__cov_WKkurTqscWZwqGjHXZ6avQ.f['7']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['16']++;var container=this.get('container'),owns=Y.Object.owns,handler,handlers,name,selector;__cov_WKkurTqscWZwqGjHXZ6avQ.s['17']++;this.detachEvents();__cov_WKkurTqscWZwqGjHXZ6avQ.s['18']++;(__cov_WKkurTqscWZwqGjHXZ6avQ.b['7'][0]++,events)||(__cov_WKkurTqscWZwqGjHXZ6avQ.b['7'][1]++,events=this.events);__cov_WKkurTqscWZwqGjHXZ6avQ.s['19']++;for(selector in events){__cov_WKkurTqscWZwqGjHXZ6avQ.s['20']++;if(!owns(events,selector)){__cov_WKkurTqscWZwqGjHXZ6avQ.b['8'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['21']++;continue;}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['8'][1]++;}__cov_WKkurTqscWZwqGjHXZ6avQ.s['22']++;handlers=events[selector];__cov_WKkurTqscWZwqGjHXZ6avQ.s['23']++;for(name in handlers){__cov_WKkurTqscWZwqGjHXZ6avQ.s['24']++;if(!owns(handlers,name)){__cov_WKkurTqscWZwqGjHXZ6avQ.b['9'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['25']++;continue;}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['9'][1]++;}__cov_WKkurTqscWZwqGjHXZ6avQ.s['26']++;handler=handlers[name];__cov_WKkurTqscWZwqGjHXZ6avQ.s['27']++;if(typeof handler==='string'){__cov_WKkurTqscWZwqGjHXZ6avQ.b['10'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['28']++;handler=this[handler];}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['10'][1]++;}__cov_WKkurTqscWZwqGjHXZ6avQ.s['29']++;if(!handler){__cov_WKkurTqscWZwqGjHXZ6avQ.b['11'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['30']++;continue;}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['11'][1]++;}__cov_WKkurTqscWZwqGjHXZ6avQ.s['31']++;this._attachedViewEvents.push(container.delegate(name,handler,selector,this));}}__cov_WKkurTqscWZwqGjHXZ6avQ.s['32']++;return this;},create:function(container){__cov_WKkurTqscWZwqGjHXZ6avQ.f['8']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['33']++;return container?(__cov_WKkurTqscWZwqGjHXZ6avQ.b['12'][0]++,Y.one(container)):(__cov_WKkurTqscWZwqGjHXZ6avQ.b['12'][1]++,Y.Node.create(this.containerTemplate));},detachEvents:function(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['9']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['34']++;Y.Array.each(this._attachedViewEvents,function(handle){__cov_WKkurTqscWZwqGjHXZ6avQ.f['10']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['35']++;if(handle){__cov_WKkurTqscWZwqGjHXZ6avQ.b['13'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['36']++;handle.detach();}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['13'][1]++;}});__cov_WKkurTqscWZwqGjHXZ6avQ.s['37']++;this._attachedViewEvents=[];__cov_WKkurTqscWZwqGjHXZ6avQ.s['38']++;return this;},remove:function(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['11']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['39']++;var container=this.get('container');__cov_WKkurTqscWZwqGjHXZ6avQ.s['40']++;(__cov_WKkurTqscWZwqGjHXZ6avQ.b['14'][0]++,container)&&(__cov_WKkurTqscWZwqGjHXZ6avQ.b['14'][1]++,container.remove());__cov_WKkurTqscWZwqGjHXZ6avQ.s['41']++;return this;},render:function(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['12']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['42']++;return this;},_destroyContainer:function(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['13']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['43']++;var container=this.get('container');__cov_WKkurTqscWZwqGjHXZ6avQ.s['44']++;(__cov_WKkurTqscWZwqGjHXZ6avQ.b['15'][0]++,container)&&(__cov_WKkurTqscWZwqGjHXZ6avQ.b['15'][1]++,container.remove(true));},_getContainer:function(value){__cov_WKkurTqscWZwqGjHXZ6avQ.f['14']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['45']++;if(!this._container){__cov_WKkurTqscWZwqGjHXZ6avQ.b['16'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['46']++;if(value){__cov_WKkurTqscWZwqGjHXZ6avQ.b['17'][0]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['47']++;this._container=value;__cov_WKkurTqscWZwqGjHXZ6avQ.s['48']++;this.attachEvents();}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['17'][1]++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['49']++;value=this._container=this.create();__cov_WKkurTqscWZwqGjHXZ6avQ.s['50']++;this._set('container',value);}}else{__cov_WKkurTqscWZwqGjHXZ6avQ.b['16'][1]++;}__cov_WKkurTqscWZwqGjHXZ6avQ.s['51']++;return value;},_afterContainerChange:function(){__cov_WKkurTqscWZwqGjHXZ6avQ.f['15']++;__cov_WKkurTqscWZwqGjHXZ6avQ.s['52']++;this.attachEvents(this.events);}},{NAME:'view',ATTRS:{container:{getter:'_getContainer',setter:Y.one,writeOnce:true}},_NON_ATTRS_CFG:['containerTemplate','events','template']});},'patched-v3.18.0',{'requires':['base-build','node-event-delegate']});
  