Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

Revision 538977 of Transferable

  • Revision slug: Web/API/Transferable
  • Revision title: Transferable
  • Revision id: 538977
  • Created:
  • Creator: teoli
  • Is current revision? No
  • Comment

Revision Content

{{ DomRef() }}

The Transferable interface represents an object that can be transfered between different execution contexts, like the main thread and Web workers.

This is an abstract interface and there isn't any object of this type. It also doesn't define any method or property: it is merely a tag indicating objects that can be used in specific conditions, like to be transfered to a {{domxref("Worker")}} using the {{domxref("Worker.postMessage()")}} method.

The {{domxref("ArrayBuffer")}} and {{domxref("MessagePort")}} implement it.

Properties

The Transferable interface doesn't implement nor inherit specific properties.

Methods

The Transferable interface doesn't implement nor inherit specific properties.

Specifications

Specification Status Comment
{{SpecName('HTML WHATWG', "infrastructure.html#transferable-objects", "Transferable")}} {{Spec2('HTML WHATWG')}} No change from {{SpecName("HTML5 W3C")}}, though the new {{domxref("CanvasProxy")}} does implement Transferable.
{{SpecName('HTML5 W3C', "infrastructure.html#transferable-objects", "Transferable")}} {{Spec2('HTML5 W3C')}} Initial definition.

Browser compatibility

{{CompatibilityTable}}
Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari (WebKit)
Basic support {{CompatVersionUnknown}} {{CompatGeckoDesktop("2.0")}} 10.0 [1] {{CompatVersionUnknown}} {{CompatVersionUnknown}}
MessagePort {{CompatUnknown}} {{CompatNo}} {{CompatUnknown}} {{CompatUnknown}} {{CompatUnknown}}
Feature Android Firefox Mobile (Gecko) IE Phone Opera Mobile Safari Mobile
Basic support {{CompatVersionUnknown}} {{CompatGeckoMobile("2.0")}} 10.0 [1] {{CompatVersionUnknown}} {{CompatVersionUnknown}}
MessagePort {{CompatUnknown}} {{CompatNo}} {{CompatUnknown}} {{CompatUnknown}} {{CompatUnknown}}

[1] Internet Explorer 10 only accepts a single {{domxref("Transferable")}} object as parameter, but not an array.

See also

  • Interfaces implementing it: {{domxref("ArrayBuffer")}}, {{domxref("MessagePort")}}.

Revision Source

<p>{{ DomRef() }}</p>
<p>The <code><strong>Transferable</strong></code> interface represents an object that can be transfered between different execution contexts, like the main thread and Web workers.</p>
<p>This is an abstract interface and there isn't any object of this type. It also doesn't define any method or property: it is merely a tag indicating objects that can be used in specific conditions, like to be transfered to a {{domxref("Worker")}} using the {{domxref("Worker.postMessage()")}} method.</p>
<p>The {{domxref("ArrayBuffer")}} and {{domxref("MessagePort")}} implement it.</p>
<h2 id="Properties">Properties</h2>
<p><em>The </em><em><code>Transferable</code></em><em> interface doesn't implement nor inherit specific properties.</em></p>
<h2 id="Methods">Methods</h2>
<p><em>The </em><em><code>Transferable</code></em><em> interface doesn't implement nor inherit specific properties.</em></p>
<h2 id="Specifications">Specifications</h2>
<table class="standard-table">
 <tbody>
  <tr>
   <th scope="col">Specification</th>
   <th scope="col">Status</th>
   <th scope="col">Comment</th>
  </tr>
  <tr>
   <td>{{SpecName('HTML WHATWG', "infrastructure.html#transferable-objects", "Transferable")}}</td>
   <td>{{Spec2('HTML WHATWG')}}</td>
   <td>No change from {{SpecName("HTML5 W3C")}}, though the new {{domxref("CanvasProxy")}} does implement <code>Transferable</code>.</td>
  </tr>
  <tr>
   <td>{{SpecName('HTML5 W3C', "infrastructure.html#transferable-objects", "Transferable")}}</td>
   <td>{{Spec2('HTML5 W3C')}}</td>
   <td>Initial definition.</td>
  </tr>
 </tbody>
</table>
<h2 id="Browser_compatibility">Browser compatibility</h2>
<div>
 {{CompatibilityTable}}</div>
<div id="compat-desktop">
 <table class="compat-table">
  <tbody>
   <tr>
    <th>Feature</th>
    <th>Chrome</th>
    <th>Firefox (Gecko)</th>
    <th>Internet Explorer</th>
    <th>Opera</th>
    <th>Safari (WebKit)</th>
   </tr>
   <tr>
    <td>Basic support</td>
    <td>{{CompatVersionUnknown}}</td>
    <td>{{CompatGeckoDesktop("2.0")}}</td>
    <td>10.0 [1]</td>
    <td>{{CompatVersionUnknown}}</td>
    <td>{{CompatVersionUnknown}}</td>
   </tr>
   <tr>
    <td><code>MessagePort</code></td>
    <td>{{CompatUnknown}}</td>
    <td>{{CompatNo}}</td>
    <td>{{CompatUnknown}}</td>
    <td>{{CompatUnknown}}</td>
    <td>{{CompatUnknown}}</td>
   </tr>
  </tbody>
 </table>
</div>
<div id="compat-mobile">
 <table class="compat-table">
  <tbody>
   <tr>
    <th>Feature</th>
    <th>Android</th>
    <th>Firefox Mobile (Gecko)</th>
    <th>IE Phone</th>
    <th>Opera Mobile</th>
    <th>Safari Mobile</th>
   </tr>
   <tr>
    <td>Basic support</td>
    <td>{{CompatVersionUnknown}}</td>
    <td>{{CompatGeckoMobile("2.0")}}</td>
    <td>10.0 [1]</td>
    <td>{{CompatVersionUnknown}}</td>
    <td>{{CompatVersionUnknown}}</td>
   </tr>
   <tr>
    <td><code>MessagePort</code></td>
    <td>{{CompatUnknown}}</td>
    <td>{{CompatNo}}</td>
    <td>{{CompatUnknown}}</td>
    <td>{{CompatUnknown}}</td>
    <td>{{CompatUnknown}}</td>
   </tr>
  </tbody>
 </table>
</div>
<p>[1] Internet Explorer 10 only accepts a single {{domxref("Transferable")}} object as parameter, but not an array.</p>
<h2 id="See_also">See also</h2>
<ul>
 <li>Interfaces implementing it: {{domxref("ArrayBuffer")}}, {{domxref("MessagePort")}}.</li>
</ul>
Revert to this revision