OLD | NEW |
1 var _interceptors; | 1 var _interceptors; |
2 (function(_interceptors) { | 2 (function(exports) { |
3 'use strict'; | 3 'use strict'; |
4 // Function _symbolToString: (Symbol) → String | 4 // Function _symbolToString: (Symbol) → String |
5 function _symbolToString(symbol) { | 5 function _symbolToString(symbol) { |
6 return _internal.Symbol.getName(dart.as(symbol, _internal.Symbol)); | 6 return _internal.Symbol.getName(dart.as(symbol, _internal.Symbol)); |
7 } | 7 } |
8 // Function _symbolMapToStringMap: (Map<Symbol, dynamic>) → dynamic | 8 // Function _symbolMapToStringMap: (Map<Symbol, dynamic>) → dynamic |
9 function _symbolMapToStringMap(map) { | 9 function _symbolMapToStringMap(map) { |
10 if (map === null) | 10 if (map === null) |
11 return null; | 11 return null; |
12 let result = new core.Map(); | 12 let result = new core.Map(); |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 if (interceptor === null) { | 76 if (interceptor === null) { |
77 let proto = Object.getPrototypeOf(object); | 77 let proto = Object.getPrototypeOf(object); |
78 if (proto == null || proto === Object.prototype) { | 78 if (proto == null || proto === Object.prototype) { |
79 return _foreign_helper.JS_INTERCEPTOR_CONSTANT(PlainJavaScriptObject); | 79 return _foreign_helper.JS_INTERCEPTOR_CONSTANT(PlainJavaScriptObject); |
80 } else { | 80 } else { |
81 return _foreign_helper.JS_INTERCEPTOR_CONSTANT(UnknownJavaScriptObject); | 81 return _foreign_helper.JS_INTERCEPTOR_CONSTANT(UnknownJavaScriptObject); |
82 } | 82 } |
83 } | 83 } |
84 return interceptor; | 84 return interceptor; |
85 } | 85 } |
86 dart.copyProperties(_interceptors, { | 86 dart.copyProperties(exports, { |
87 get mapTypeToInterceptor() { | 87 get mapTypeToInterceptor() { |
88 return _foreign_helper.JS_EMBEDDED_GLOBAL('', dart.as(_js_embedded_names.M
AP_TYPE_TO_INTERCEPTOR, core.String)); | 88 return _foreign_helper.JS_EMBEDDED_GLOBAL('', dart.as(_js_embedded_names.M
AP_TYPE_TO_INTERCEPTOR, core.String)); |
89 } | 89 } |
90 }); | 90 }); |
91 // Function findIndexForNativeSubclassType: (Type) → int | 91 // Function findIndexForNativeSubclassType: (Type) → int |
92 function findIndexForNativeSubclassType(type) { | 92 function findIndexForNativeSubclassType(type) { |
93 if (_interceptors.mapTypeToInterceptor == null) | 93 if (exports.mapTypeToInterceptor == null) |
94 return dart.as(null, core.int); | 94 return dart.as(null, core.int); |
95 let map = dart.as(_interceptors.mapTypeToInterceptor, core.List); | 95 let map = dart.as(exports.mapTypeToInterceptor, core.List); |
96 for (let i = 0; i + 1 < map.length; i = 3) { | 96 for (let i = 0; i + 1 < map.length; i = 3) { |
97 if (dart.equals(type, map.get(i))) { | 97 if (dart.equals(type, map.get(i))) { |
98 return i; | 98 return i; |
99 } | 99 } |
100 } | 100 } |
101 return dart.as(null, core.int); | 101 return dart.as(null, core.int); |
102 } | 102 } |
103 // Function findInterceptorConstructorForType: (Type) → dynamic | 103 // Function findInterceptorConstructorForType: (Type) → dynamic |
104 function findInterceptorConstructorForType(type) { | 104 function findInterceptorConstructorForType(type) { |
105 let index = findIndexForNativeSubclassType(type); | 105 let index = findIndexForNativeSubclassType(type); |
106 if (index === null) | 106 if (index === null) |
107 return null; | 107 return null; |
108 let map = dart.as(_interceptors.mapTypeToInterceptor, core.List); | 108 let map = dart.as(exports.mapTypeToInterceptor, core.List); |
109 return map.get(index + 1); | 109 return map.get(index + 1); |
110 } | 110 } |
111 // Function findConstructorForNativeSubclassType: (Type, String) → dynamic | 111 // Function findConstructorForNativeSubclassType: (Type, String) → dynamic |
112 function findConstructorForNativeSubclassType(type, name) { | 112 function findConstructorForNativeSubclassType(type, name) { |
113 let index = findIndexForNativeSubclassType(type); | 113 let index = findIndexForNativeSubclassType(type); |
114 if (index === null) | 114 if (index === null) |
115 return null; | 115 return null; |
116 let map = dart.as(_interceptors.mapTypeToInterceptor, core.List); | 116 let map = dart.as(exports.mapTypeToInterceptor, core.List); |
117 let constructorMap = map.get(index + 2); | 117 let constructorMap = map.get(index + 2); |
118 let constructorFn = constructorMap[name]; | 118 let constructorFn = constructorMap[name]; |
119 return constructorFn; | 119 return constructorFn; |
120 } | 120 } |
121 // Function findInterceptorForType: (Type) → dynamic | 121 // Function findInterceptorForType: (Type) → dynamic |
122 function findInterceptorForType(type) { | 122 function findInterceptorForType(type) { |
123 let constructor = findInterceptorConstructorForType(type); | 123 let constructor = findInterceptorConstructorForType(type); |
124 if (constructor === null) | 124 if (constructor === null) |
125 return null; | 125 return null; |
126 return constructor.prototype; | 126 return constructor.prototype; |
(...skipping 1226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1353 super.UnmodifiableListBase(); | 1353 super.UnmodifiableListBase(); |
1354 } | 1354 } |
1355 get length() { | 1355 get length() { |
1356 return this._string.length; | 1356 return this._string.length; |
1357 } | 1357 } |
1358 get(i) { | 1358 get(i) { |
1359 return this._string.codeUnitAt(i); | 1359 return this._string.codeUnitAt(i); |
1360 } | 1360 } |
1361 } | 1361 } |
1362 // Exports: | 1362 // Exports: |
1363 _interceptors.getInterceptor = getInterceptor; | 1363 exports.getInterceptor = getInterceptor; |
1364 _interceptors.getDispatchProperty = getDispatchProperty; | 1364 exports.getDispatchProperty = getDispatchProperty; |
1365 _interceptors.setDispatchProperty = setDispatchProperty; | 1365 exports.setDispatchProperty = setDispatchProperty; |
1366 _interceptors.makeDispatchRecord = makeDispatchRecord; | 1366 exports.makeDispatchRecord = makeDispatchRecord; |
1367 _interceptors.dispatchRecordInterceptor = dispatchRecordInterceptor; | 1367 exports.dispatchRecordInterceptor = dispatchRecordInterceptor; |
1368 _interceptors.dispatchRecordProto = dispatchRecordProto; | 1368 exports.dispatchRecordProto = dispatchRecordProto; |
1369 _interceptors.dispatchRecordExtension = dispatchRecordExtension; | 1369 exports.dispatchRecordExtension = dispatchRecordExtension; |
1370 _interceptors.dispatchRecordIndexability = dispatchRecordIndexability; | 1370 exports.dispatchRecordIndexability = dispatchRecordIndexability; |
1371 _interceptors.getNativeInterceptor = getNativeInterceptor; | 1371 exports.getNativeInterceptor = getNativeInterceptor; |
1372 _interceptors.mapTypeToInterceptor = mapTypeToInterceptor; | 1372 exports.mapTypeToInterceptor = mapTypeToInterceptor; |
1373 _interceptors.findIndexForNativeSubclassType = findIndexForNativeSubclassType; | 1373 exports.findIndexForNativeSubclassType = findIndexForNativeSubclassType; |
1374 _interceptors.findInterceptorConstructorForType = findInterceptorConstructorFo
rType; | 1374 exports.findInterceptorConstructorForType = findInterceptorConstructorForType; |
1375 _interceptors.findConstructorForNativeSubclassType = findConstructorForNativeS
ubclassType; | 1375 exports.findConstructorForNativeSubclassType = findConstructorForNativeSubclas
sType; |
1376 _interceptors.findInterceptorForType = findInterceptorForType; | 1376 exports.findInterceptorForType = findInterceptorForType; |
1377 _interceptors.Interceptor = Interceptor; | 1377 exports.Interceptor = Interceptor; |
1378 _interceptors.JSBool = JSBool; | 1378 exports.JSBool = JSBool; |
1379 _interceptors.JSNull = JSNull; | 1379 exports.JSNull = JSNull; |
1380 _interceptors.JSIndexable = JSIndexable; | 1380 exports.JSIndexable = JSIndexable; |
1381 _interceptors.JSMutableIndexable = JSMutableIndexable; | 1381 exports.JSMutableIndexable = JSMutableIndexable; |
1382 _interceptors.JSObject = JSObject; | 1382 exports.JSObject = JSObject; |
1383 _interceptors.JavaScriptObject = JavaScriptObject; | 1383 exports.JavaScriptObject = JavaScriptObject; |
1384 _interceptors.PlainJavaScriptObject = PlainJavaScriptObject; | 1384 exports.PlainJavaScriptObject = PlainJavaScriptObject; |
1385 _interceptors.UnknownJavaScriptObject = UnknownJavaScriptObject; | 1385 exports.UnknownJavaScriptObject = UnknownJavaScriptObject; |
1386 _interceptors.JSArray = JSArray; | 1386 exports.JSArray = JSArray; |
1387 _interceptors.JSArray$ = JSArray$; | 1387 exports.JSArray$ = JSArray$; |
1388 _interceptors.JSMutableArray = JSMutableArray; | 1388 exports.JSMutableArray = JSMutableArray; |
1389 _interceptors.JSMutableArray$ = JSMutableArray$; | 1389 exports.JSMutableArray$ = JSMutableArray$; |
1390 _interceptors.JSFixedArray = JSFixedArray; | 1390 exports.JSFixedArray = JSFixedArray; |
1391 _interceptors.JSFixedArray$ = JSFixedArray$; | 1391 exports.JSFixedArray$ = JSFixedArray$; |
1392 _interceptors.JSExtendableArray = JSExtendableArray; | 1392 exports.JSExtendableArray = JSExtendableArray; |
1393 _interceptors.JSExtendableArray$ = JSExtendableArray$; | 1393 exports.JSExtendableArray$ = JSExtendableArray$; |
1394 _interceptors.JSNumber = JSNumber; | 1394 exports.JSNumber = JSNumber; |
1395 _interceptors.JSInt = JSInt; | 1395 exports.JSInt = JSInt; |
1396 _interceptors.JSDouble = JSDouble; | 1396 exports.JSDouble = JSDouble; |
1397 _interceptors.JSPositiveInt = JSPositiveInt; | 1397 exports.JSPositiveInt = JSPositiveInt; |
1398 _interceptors.JSUInt32 = JSUInt32; | 1398 exports.JSUInt32 = JSUInt32; |
1399 _interceptors.JSUInt31 = JSUInt31; | 1399 exports.JSUInt31 = JSUInt31; |
1400 _interceptors.JSString = JSString; | 1400 exports.JSString = JSString; |
1401 })(_interceptors || (_interceptors = {})); | 1401 })(_interceptors || (_interceptors = {})); |
OLD | NEW |