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

Side by Side Diff: lib/isolate/isolate_api.dart

Issue 9691005: Implement spawnFunction from the new isolate api. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 9 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 | runtime/lib/isolate.cc » ('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 (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 class IsolateSpawnException implements Exception {
Siggi Cherem (dart-lang) 2012/03/13 23:00:14 (nit): move this to the bottom, so that the top of
6 const IsolateSpawnException(String this._s);
7 String toString() => "IsolateSpawnException: '$_s'";
8 final String _s;
9 }
10
5 /** 11 /**
6 * The initial [ReceivePort] available by default for this isolate. This 12 * The initial [ReceivePort] available by default for this isolate. This
7 * [ReceivePort] is created automatically and it is commonly used to establish 13 * [ReceivePort] is created automatically and it is commonly used to establish
8 * the first communication between isolates (see [spawnFunction] and 14 * the first communication between isolates (see [spawnFunction] and
9 * [spawnUri]). 15 * [spawnUri]).
10 */ 16 */
11 ReceivePort get port() => _port; 17 ReceivePort get port() => _port;
12 18
13 /** 19 /**
14 * Creates and spawns an isolate that shares the same code as the current 20 * Creates and spawns an isolate that shares the same code as the current
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
216 /** 222 /**
217 * When isolates are created, an instance of the template's class is 223 * When isolates are created, an instance of the template's class is
218 * instantiated in the new isolate. After the [port] has been set up, this 224 * instantiated in the new isolate. After the [port] has been set up, this
219 * [main] method is invoked on the instance. 225 * [main] method is invoked on the instance.
220 */ 226 */
221 abstract void main(); 227 abstract void main();
222 228
223 final bool _isLight; 229 final bool _isLight;
224 ReceivePort _port; 230 ReceivePort _port;
225 } 231 }
OLDNEW
« no previous file with comments | « no previous file | runtime/lib/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698