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

Side by Side Diff: Source/bindings/core/v8/ScriptFunctionCall.h

Issue 1278983003: Adding allocator annotations to blink classes and structs. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed patch conflict Created 5 years, 4 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
« no previous file with comments | « Source/bindings/core/v8/ScriptController.h ('k') | Source/bindings/core/v8/ScriptPromise.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 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 21 matching lines...) Expand all
32 #define ScriptFunctionCall_h 32 #define ScriptFunctionCall_h
33 33
34 #include "bindings/core/v8/ScriptValue.h" 34 #include "bindings/core/v8/ScriptValue.h"
35 #include "wtf/Vector.h" 35 #include "wtf/Vector.h"
36 #include "wtf/text/WTFString.h" 36 #include "wtf/text/WTFString.h"
37 37
38 namespace blink { 38 namespace blink {
39 class ScriptValue; 39 class ScriptValue;
40 40
41 class ScriptCallArgumentHandler { 41 class ScriptCallArgumentHandler {
42 STACK_ALLOCATED();
42 public: 43 public:
43 ScriptCallArgumentHandler(ScriptState* scriptState) : m_scriptState(scriptSt ate) { } 44 ScriptCallArgumentHandler(ScriptState* scriptState) : m_scriptState(scriptSt ate) { }
44 45
45 void appendArgument(v8::Local<v8::Value>); 46 void appendArgument(v8::Local<v8::Value>);
46 void appendArgument(const ScriptValue&); 47 void appendArgument(const ScriptValue&);
47 void appendArgument(const String&); 48 void appendArgument(const String&);
48 void appendArgument(int); 49 void appendArgument(int);
49 void appendArgument(bool); 50 void appendArgument(bool);
50 void appendUndefinedArgument(); 51 void appendUndefinedArgument();
51 52
52 protected: 53 protected:
53 RefPtr<ScriptState> m_scriptState; 54 RefPtr<ScriptState> m_scriptState;
54 Vector<ScriptValue> m_arguments; 55 Vector<ScriptValue> m_arguments;
55 }; 56 };
56 57
57 class ScriptFunctionCall : public ScriptCallArgumentHandler { 58 class ScriptFunctionCall : public ScriptCallArgumentHandler {
59 STACK_ALLOCATED();
58 public: 60 public:
59 ScriptFunctionCall(const ScriptValue& thisObject, const String& name); 61 ScriptFunctionCall(const ScriptValue& thisObject, const String& name);
60 ScriptValue call(bool& hadException, bool reportExceptions = true); 62 ScriptValue call(bool& hadException, bool reportExceptions = true);
61 ScriptValue call(); 63 ScriptValue call();
62 v8::Handle<v8::Function> function(); 64 v8::Handle<v8::Function> function();
63 ScriptValue callWithoutExceptionHandling(); 65 ScriptValue callWithoutExceptionHandling();
64 66
65 protected: 67 protected:
66 ScriptValue m_thisObject; 68 ScriptValue m_thisObject;
67 String m_name; 69 String m_name;
68 }; 70 };
69 71
70 } // namespace blink 72 } // namespace blink
71 73
72 #endif // ScriptFunctionCall 74 #endif // ScriptFunctionCall
OLDNEW
« no previous file with comments | « Source/bindings/core/v8/ScriptController.h ('k') | Source/bindings/core/v8/ScriptPromise.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698