OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 Sources.SourceMapNamesResolver = {}; | 4 Sources.SourceMapNamesResolver = {}; |
5 | 5 |
6 Sources.SourceMapNamesResolver._cachedMapSymbol = Symbol('cache'); | 6 Sources.SourceMapNamesResolver._cachedMapSymbol = Symbol('cache'); |
7 Sources.SourceMapNamesResolver._cachedIdentifiersSymbol = Symbol('cachedIdentifi
ers'); | 7 Sources.SourceMapNamesResolver._cachedIdentifiersSymbol = Symbol('cachedIdentifi
ers'); |
8 | 8 |
9 /** | 9 /** |
10 * @unrestricted | 10 * @unrestricted |
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
394 /** | 394 /** |
395 * @override | 395 * @override |
396 * @return {number} | 396 * @return {number} |
397 */ | 397 */ |
398 arrayLength() { | 398 arrayLength() { |
399 return this._object.arrayLength(); | 399 return this._object.arrayLength(); |
400 } | 400 } |
401 | 401 |
402 /** | 402 /** |
403 * @override | 403 * @override |
| 404 * @param {boolean} generatePreview |
404 * @param {function(?Array.<!SDK.RemoteObjectProperty>, ?Array.<!SDK.RemoteObj
ectProperty>)} callback | 405 * @param {function(?Array.<!SDK.RemoteObjectProperty>, ?Array.<!SDK.RemoteObj
ectProperty>)} callback |
405 */ | 406 */ |
406 getOwnProperties(callback) { | 407 getOwnProperties(generatePreview, callback) { |
407 this._object.getOwnProperties(callback); | 408 this._object.getOwnProperties(generatePreview, callback); |
408 } | 409 } |
409 | 410 |
410 /** | 411 /** |
411 * @override | 412 * @override |
412 * @param {boolean} accessorPropertiesOnly | 413 * @param {boolean} accessorPropertiesOnly |
| 414 * @param {boolean} generatePreview |
413 * @param {function(?Array<!SDK.RemoteObjectProperty>, ?Array<!SDK.RemoteObjec
tProperty>)} callback | 415 * @param {function(?Array<!SDK.RemoteObjectProperty>, ?Array<!SDK.RemoteObjec
tProperty>)} callback |
414 */ | 416 */ |
415 getAllProperties(accessorPropertiesOnly, callback) { | 417 getAllProperties(accessorPropertiesOnly, generatePreview, callback) { |
416 /** | 418 /** |
417 * @param {?Array.<!SDK.RemoteObjectProperty>} properties | 419 * @param {?Array.<!SDK.RemoteObjectProperty>} properties |
418 * @param {?Array.<!SDK.RemoteObjectProperty>} internalProperties | 420 * @param {?Array.<!SDK.RemoteObjectProperty>} internalProperties |
419 * @this {Sources.SourceMapNamesResolver.RemoteObject} | 421 * @this {Sources.SourceMapNamesResolver.RemoteObject} |
420 */ | 422 */ |
421 function wrappedCallback(properties, internalProperties) { | 423 function wrappedCallback(properties, internalProperties) { |
422 Sources.SourceMapNamesResolver._resolveScope(this._scope) | 424 Sources.SourceMapNamesResolver._resolveScope(this._scope) |
423 .then(resolveNames.bind(null, properties, internalProperties)); | 425 .then(resolveNames.bind(null, properties, internalProperties)); |
424 } | 426 } |
425 | 427 |
(...skipping 10 matching lines...) Expand all Loading... |
436 var name = namesMapping.get(property.name) || properties[i].name; | 438 var name = namesMapping.get(property.name) || properties[i].name; |
437 newProperties.push(new SDK.RemoteObjectProperty( | 439 newProperties.push(new SDK.RemoteObjectProperty( |
438 name, property.value, property.enumerable, property.writable, prop
erty.isOwn, property.wasThrown, | 440 name, property.value, property.enumerable, property.writable, prop
erty.isOwn, property.wasThrown, |
439 property.symbol, property.synthetic)); | 441 property.symbol, property.synthetic)); |
440 } | 442 } |
441 } | 443 } |
442 | 444 |
443 callback(newProperties, internalProperties); | 445 callback(newProperties, internalProperties); |
444 } | 446 } |
445 | 447 |
446 this._object.getAllProperties(accessorPropertiesOnly, wrappedCallback.bind(t
his)); | 448 this._object.getAllProperties(accessorPropertiesOnly, generatePreview, wrapp
edCallback.bind(this)); |
447 } | 449 } |
448 | 450 |
449 /** | 451 /** |
450 * @override | 452 * @override |
451 * @param {string|!Protocol.Runtime.CallArgument} argumentName | 453 * @param {string|!Protocol.Runtime.CallArgument} argumentName |
452 * @param {string} value | 454 * @param {string} value |
453 * @param {function(string=)} callback | 455 * @param {function(string=)} callback |
454 */ | 456 */ |
455 setPropertyValue(argumentName, value, callback) { | 457 setPropertyValue(argumentName, value, callback) { |
456 Sources.SourceMapNamesResolver._resolveScope(this._scope).then(resolveName.b
ind(this)); | 458 Sources.SourceMapNamesResolver._resolveScope(this._scope).then(resolveName.b
ind(this)); |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
531 } | 533 } |
532 | 534 |
533 /** | 535 /** |
534 * @override | 536 * @override |
535 * @return {boolean} | 537 * @return {boolean} |
536 */ | 538 */ |
537 isNode() { | 539 isNode() { |
538 return this._object.isNode(); | 540 return this._object.isNode(); |
539 } | 541 } |
540 }; | 542 }; |
OLD | NEW |