/**
 * * Licensed under the Apache License, Version 2.0 (the 'License');
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an 'AS IS' BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 * Generated by Apache Flex Cross-Compiler from org/apache/flex/net/URLLoader.as
 * org.apache.flex.net.URLLoader
 *
 * @fileoverview
 *
 * @suppress {checkTypes|accessControls}
 */

goog.provide('org.apache.flex.net.URLLoader');

goog.require('org.apache.flex.events.EventDispatcher');
goog.require('org.apache.flex.utils.Language');



/**
 * @constructor
 * @extends {org.apache.flex.events.EventDispatcher}
 */
org.apache.flex.net.URLLoader = function() {
  org.apache.flex.net.URLLoader.base(this, 'constructor');
};
goog.inherits(org.apache.flex.net.URLLoader, org.apache.flex.events.EventDispatcher);


/**
 * @export
 * @type {number}
 */
org.apache.flex.net.URLLoader.prototype.requestStatus;


/**
 * @protected
 */
org.apache.flex.net.URLLoader.prototype.cleanupCallbacks = function() {
  this.onComplete = null;
  this.onError = null;
  this.onProgress = null;
  this.onStatus = null;
};


/**
 * @export
 * @type {Function}
 */
org.apache.flex.net.URLLoader.prototype.onComplete;


/**
 * @export
 * @type {Function}
 */
org.apache.flex.net.URLLoader.prototype.onError;


/**
 * @export
 * @type {Function}
 */
org.apache.flex.net.URLLoader.prototype.onProgress;


/**
 * @export
 * @type {Function}
 */
org.apache.flex.net.URLLoader.prototype.onStatus;


/**
 *  Convenience function for complete event to allow chaining.
 *  
 *  @langversion 3.0
 *  @playerversion Flash 10.2
 *  @playerversion AIR 2.6
 *  @productversion FlexJS 0.7.0
 * @export
 * @param {Function} callback
 * @return {org.apache.flex.net.URLLoader}
 */
org.apache.flex.net.URLLoader.prototype.complete = function(callback) {
  this.onComplete = callback;
  return this;
};


/**
 *  Convenience function for error event to allow chaining.
 *  
 *  @langversion 3.0
 *  @playerversion Flash 10.2
 *  @playerversion AIR 2.6
 *  @productversion FlexJS 0.7.0
 * @export
 * @param {Function} callback
 * @return {org.apache.flex.net.URLLoader}
 */
org.apache.flex.net.URLLoader.prototype.error = function(callback) {
  this.onError = callback;
  return this;
};


/**
 *  Convenience function for progress event to allow chaining.
 *  
 *  @langversion 3.0
 *  @playerversion Flash 10.2
 *  @playerversion AIR 2.6
 *  @productversion FlexJS 0.7.0
 * @export
 * @param {Function} callback
 * @return {org.apache.flex.net.URLLoader}
 */
org.apache.flex.net.URLLoader.prototype.progress = function(callback) {
  this.onProgress = callback;
  return this;
};


/**
 *  Convenience function for status event to allow chaining.
 *  
 *  @langversion 3.0
 *  @playerversion Flash 10.2
 *  @playerversion AIR 2.6
 *  @productversion FlexJS 0.7.0
 * @export
 * @param {Function} callback
 * @return {org.apache.flex.net.URLLoader}
 */
org.apache.flex.net.URLLoader.prototype.status = function(callback) {
  this.onStatus = callback;
  return this;
};


/**
 * Metadata
 *
 * @type {Object.<string, Array.<Object>>}
 */
org.apache.flex.net.URLLoader.prototype.FLEXJS_CLASS_INFO = { names: [{ name: 'URLLoader', qName: 'org.apache.flex.net.URLLoader'}] };


/**
 * Prevent renaming of class. Needed for reflection.
 */
goog.exportSymbol('org.apache.flex.net.URLLoader', org.apache.flex.net.URLLoader);



/**
 * Reflection
 *
 * @return {Object.<string, Function>}
 */
org.apache.flex.net.URLLoader.prototype.FLEXJS_REFLECTION_INFO = function () {
  return {
    variables: function () {
      return {
        'requestStatus': { type: 'int'},
        'onComplete': { type: 'Function'},
        'onError': { type: 'Function'},
        'onProgress': { type: 'Function'},
        'onStatus': { type: 'Function'}
      };
    },
    accessors: function () {
      return {
      };
    },
    methods: function () {
      return {
        'URLLoader': { type: '', declaredBy: 'org.apache.flex.net.URLLoader'},
        'complete': { type: 'URLLoader', declaredBy: 'org.apache.flex.net.URLLoader'},
        'error': { type: 'URLLoader', declaredBy: 'org.apache.flex.net.URLLoader'},
        'progress': { type: 'URLLoader', declaredBy: 'org.apache.flex.net.URLLoader'},
        'status': { type: 'URLLoader', declaredBy: 'org.apache.flex.net.URLLoader'}
      };
    },
    metadata: function () { return [ ]; }
  };
};