Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(106)

Side by Side Diff: include/v8.h

Issue 90003: Make it possible to add a user data object to each script compiled (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | src/accessors.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2007-2008 the V8 project authors. All rights reserved. 1 // Copyright 2007-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 511 matching lines...) Expand 10 before | Expand all | Expand 10 after
522 522
523 /** 523 /**
524 * Runs the script returning the resulting value. 524 * Runs the script returning the resulting value.
525 */ 525 */
526 Local<Value> Run(); 526 Local<Value> Run();
527 527
528 /** 528 /**
529 * Returns the script id value. 529 * Returns the script id value.
530 */ 530 */
531 Local<Value> Id(); 531 Local<Value> Id();
532
533 /**
534 * Associate an additional data object with the script. This is mainly used
535 * with the debugger as this data object is only available through the
536 * debugger API.
537 */
538 void SetData(Handle<Value> data);
532 }; 539 };
533 540
534 541
535 /** 542 /**
536 * An error message. 543 * An error message.
537 */ 544 */
538 class V8EXPORT Message { 545 class V8EXPORT Message {
539 public: 546 public:
540 Local<String> Get() const; 547 Local<String> Get() const;
541 Local<String> GetSourceLine() const; 548 Local<String> GetSourceLine() const;
542 549
550 /**
551 * Returns the resource name for the script from where the function causing
552 * the error originates.
553 */
543 Handle<Value> GetScriptResourceName() const; 554 Handle<Value> GetScriptResourceName() const;
544 555
545 /** 556 /**
557 * Returns the resource data for the script from where the function causing
558 * the error originates.
559 */
560 Handle<Value> GetScriptData() const;
561
562 /**
546 * Returns the number, 1-based, of the line where the error occurred. 563 * Returns the number, 1-based, of the line where the error occurred.
547 */ 564 */
548 int GetLineNumber() const; 565 int GetLineNumber() const;
549 566
550 /** 567 /**
551 * Returns the index within the script of the first character where 568 * Returns the index within the script of the first character where
552 * the error occurred. 569 * the error occurred.
553 */ 570 */
554 int GetStartPosition() const; 571 int GetStartPosition() const;
555 572
(...skipping 1973 matching lines...) Expand 10 before | Expand all | Expand 10 after
2529 2546
2530 } // namespace v8 2547 } // namespace v8
2531 2548
2532 2549
2533 #undef V8EXPORT 2550 #undef V8EXPORT
2534 #undef V8EXPORT_INLINE 2551 #undef V8EXPORT_INLINE
2535 #undef TYPE_CHECK 2552 #undef TYPE_CHECK
2536 2553
2537 2554
2538 #endif // V8_H_ 2555 #endif // V8_H_
OLDNEW
« no previous file with comments | « no previous file | src/accessors.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698