OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2009, 2012 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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 bool isExecutionForbidden() const; | 56 bool isExecutionForbidden() const; |
57 bool isExecutionTerminating() const; | 57 bool isExecutionTerminating() const; |
58 | 58 |
59 // Returns true if the evaluation completed with no uncaught exception. | 59 // Returns true if the evaluation completed with no uncaught exception. |
60 bool evaluate(const ScriptSourceCode&, RefPtrWillBeRawPtr<ErrorEvent>* = nul
lptr, CachedMetadataHandler* = nullptr, V8CacheOptions = V8CacheOptionsDefault); | 60 bool evaluate(const ScriptSourceCode&, RefPtrWillBeRawPtr<ErrorEvent>* = nul
lptr, CachedMetadataHandler* = nullptr, V8CacheOptions = V8CacheOptionsDefault); |
61 | 61 |
62 // Prevents future JavaScript execution. See | 62 // Prevents future JavaScript execution. See |
63 // willScheduleExecutionTermination, isExecutionForbidden. | 63 // willScheduleExecutionTermination, isExecutionForbidden. |
64 void forbidExecution(); | 64 void forbidExecution(); |
65 | 65 |
66 // Used by WorkerThread: | 66 // Used by WorkerScript: |
67 bool initializeContextIfNeeded(); | 67 bool initializeContextIfNeeded(); |
68 // Async request to terminate future JavaScript execution on the | 68 // Async request to terminate future JavaScript execution on the |
69 // worker thread. JavaScript evaluation exits with a | 69 // worker thread. JavaScript evaluation exits with a |
70 // non-continuable exception and WorkerScriptController calls | 70 // non-continuable exception and WorkerScriptController calls |
71 // forbidExecution to prevent further JavaScript execution. Use | 71 // forbidExecution to prevent further JavaScript execution. Use |
72 // forbidExecution()/isExecutionForbidden() to guard against | 72 // forbidExecution()/isExecutionForbidden() to guard against |
73 // reentry into JavaScript. | 73 // reentry into JavaScript. |
74 void willScheduleExecutionTermination(); | 74 void willScheduleExecutionTermination(); |
75 | 75 |
76 // Used by WorkerGlobalScope: | 76 // Used by WorkerGlobalScope: |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 // kept as a bare pointer here, and not a Persistent with | 110 // kept as a bare pointer here, and not a Persistent with |
111 // Oilpan enabled; stack scanning will visit the object and | 111 // Oilpan enabled; stack scanning will visit the object and |
112 // trace its on-heap fields. | 112 // trace its on-heap fields. |
113 GC_PLUGIN_IGNORE("394615") | 113 GC_PLUGIN_IGNORE("394615") |
114 WorkerGlobalScopeExecutionState* m_globalScopeExecutionState; | 114 WorkerGlobalScopeExecutionState* m_globalScopeExecutionState; |
115 }; | 115 }; |
116 | 116 |
117 } // namespace blink | 117 } // namespace blink |
118 | 118 |
119 #endif // WorkerScriptController_h | 119 #endif // WorkerScriptController_h |
OLD | NEW |