| Index: runtime/include/dart_api.h
|
| ===================================================================
|
| --- runtime/include/dart_api.h (revision 1518)
|
| +++ runtime/include/dart_api.h (working copy)
|
| @@ -390,6 +390,15 @@
|
| const Dart_Port kCloseAllPorts = 0;
|
|
|
| /**
|
| + * A create port callback.
|
| + *
|
| + * This callback allows the embedder to receive notification when a
|
| + * port is created.
|
| + */
|
| +typedef void (*Dart_CreatePortCallback)(Dart_Isolate isolate,
|
| + Dart_Port port);
|
| +
|
| +/**
|
| * A close port callback.
|
| *
|
| * This callback allows the embedder to receive notification when a
|
| @@ -409,6 +418,7 @@
|
| * execution begins, the embedder is responsible for threading issues.
|
| */
|
| DART_EXPORT void Dart_SetMessageCallbacks(
|
| + Dart_CreatePortCallback create_port_callback,
|
| Dart_PostMessageCallback post_message_callback,
|
| Dart_ClosePortCallback close_port_callback);
|
| // TODO(turnidge): Consider moving this to isolate creation so that it
|
| @@ -445,6 +455,16 @@
|
| // TODO(turnidge): Should this be removed from the public api?
|
|
|
| /**
|
| + * Creates a Dart_Port and associates it with the current isolate.
|
| + */
|
| +DART_EXPORT Dart_Port Dart_CreatePort();
|
| +
|
| +/**
|
| + * Does the current isolate have active ports?
|
| + */
|
| +DART_EXPORT bool Dart_IsolateHasActivePorts();
|
| +
|
| +/**
|
| * Posts a message for some isolate. The message is built from a raw
|
| * array.
|
| *
|
|
|