/**
 * Generated by Apache Royale Compiler from org\apache\royale\html\Tree.as
 * org.apache.royale.html.Tree
 *
 * @fileoverview
 *
 * @suppress {checkTypes|accessControls}
 */

goog.provide('org.apache.royale.html.Tree');

goog.require('org.apache.royale.collections.HierarchicalData');
goog.require('org.apache.royale.collections.TreeData');
goog.require('org.apache.royale.html.List');
goog.require('org.apache.royale.utils.Language');



/**
 * Constructor.
 * 
 *  @langversion 3.0
 *  @playerversion Flash 10.2
 *  @playerversion AIR 2.6
 *  @productversion Royale 0.0
 * @constructor
 * @extends {org.apache.royale.html.List}
 */
org.apache.royale.html.Tree = function() {
  org.apache.royale.html.Tree.base(this, 'constructor');
  this.typeNames += " Tree";
};
goog.inherits(org.apache.royale.html.Tree, org.apache.royale.html.List);


/**
 * Prevent renaming of class. Needed for reflection.
 */
goog.exportSymbol('org.apache.royale.html.Tree', org.apache.royale.html.Tree);


org.apache.royale.html.Tree.prototype.set__dataProvider = function(value) {
  if (org.apache.royale.utils.Language.is(value, org.apache.royale.collections.HierarchicalData)) {
    var /** @type {org.apache.royale.collections.TreeData} */ treeData = new org.apache.royale.collections.TreeData(org.apache.royale.utils.Language.as(value, org.apache.royale.collections.HierarchicalData));
    org.apache.royale.html.Tree.superClass_.set__dataProvider.apply(this, [ treeData] );
  } else {
    org.apache.royale.html.Tree.superClass_.set__dataProvider.apply(this, [ value] );
  }
};


Object.defineProperties(org.apache.royale.html.Tree.prototype, /** @lends {org.apache.royale.html.Tree.prototype} */ {
/**
  * @export
  * @type {Object} */
dataProvider: {
get: org.apache.royale.html.DataContainer.prototype.get__dataProvider,
set: org.apache.royale.html.Tree.prototype.set__dataProvider}}
);


/**
 * Metadata
 *
 * @type {Object.<string, Array.<Object>>}
 */
org.apache.royale.html.Tree.prototype.ROYALE_CLASS_INFO = { names: [{ name: 'Tree', qName: 'org.apache.royale.html.Tree', kind: 'class' }] };



/**
 * Reflection
 *
 * @return {Object.<string, Function>}
 */
org.apache.royale.html.Tree.prototype.ROYALE_REFLECTION_INFO = function () {
  return {
    variables: function () {return {};},
    accessors: function () {
      return {
        'dataProvider': { type: 'Object', access: 'writeonly', declaredBy: 'org.apache.royale.html.Tree'}
      };
    },
    methods: function () {
      return {
        'Tree': { type: '', declaredBy: 'org.apache.royale.html.Tree'}
      };
    }
  };
};