Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / chrome / browser / resources / options / chromeos / onc_data.js
index cc70fd0..d6dfcf6 100644 (file)
 
 cr.exportPath('cr.onc');
 
-/**
- * @typedef {(Object|Array|string|undefined)}
- */
-cr.onc.OncValue;
-
 cr.define('cr.onc', function() {
   'use strict';
 
@@ -30,8 +25,8 @@ cr.define('cr.onc', function() {
     /**
      * Returns either a managed property dictionary or an unmanaged value.
      * @param {string} key The property key.
-     * @return {cr.onc.OncValue} The property value or dictionary if it exists,
-     *     otherwise undefined.
+     * @return {?} The property value or dictionary if it exists, otherwise
+     *     undefined.
      */
     getManagedProperty: function(key) {
       var data = this.data_;
@@ -84,7 +79,7 @@ cr.define('cr.onc', function() {
     /**
      * Gets the active value of a property.
      * @param {string} key The property key.
-     * @return {cr.onc.OncValue} The property value or undefined.
+     * @return {?} The property value or undefined.
      */
     getActiveValue: function(key) {
       var property = this.getManagedProperty(key);
@@ -106,8 +101,7 @@ cr.define('cr.onc', function() {
      * Gets the translated ONC value from the result of getActiveValue() using
      * loadTimeData. If no translation exists, returns the untranslated value.
      * @param {string} key The property key.
-     * @return {cr.onc.OncValue} The translation if available or the value if
-     *     not.
+     * @return {?} The translation if available or the value if not.
      */
     getTranslatedValue: function(key) {
       var value = this.getActiveValue(key);
@@ -131,7 +125,7 @@ cr.define('cr.onc', function() {
     /**
      * Gets the recommended value of a property.
      * @param {string} key The property key.
-     * @return {cr.onc.OncValue} The property value or undefined.
+     * @return {?} The property value or undefined.
      */
     getRecommendedValue: function(key) {
       var property = this.getManagedProperty(key);
@@ -154,6 +148,7 @@ cr.define('cr.onc', function() {
       var source = this.getActiveValue('Source');
       if (source == undefined)
         return 'None';
+      assert(typeof source == 'string');
       return source;
     },
 
@@ -165,13 +160,14 @@ cr.define('cr.onc', function() {
       var security = this.getActiveValue('WiFi.Security');
       if (security == undefined)
         return 'None';
+      assert(typeof security == 'string');
       return security;
     },
 
     /**
      * Get the effective value from a Managed property ONC dictionary.
      * @param {Object} property The managed property ONC dictionary.
-     * @return {cr.onc.OncValue} The effective value or undefined.
+     * @return {?} The effective value or undefined.
      * @private
      */
     getEffectiveValueFromProperty_: function(property) {