Revision 357769 of MozMobileNetworkInfo

  • Revision slug: DOM/MozMobileNetworkInfo
  • Revision title: MozMobileNetworkInfo
  • Revision id: 357769
  • Created:
  • Creator: Jeremie
  • Is current revision? No
  • Comment

Revision Content

{{ domref() }}

{{ non-standard_header() }}

The MozMobileNetworkInfo interface allow to access information related to the network carrier. The {{domxref("window.navigator.mozMobileConnection","navigator.mozMobileConnection")}} uses it through its voice.network and data.network properties.

Interface

interface MozMobileNetworkInfo
{
  readonly attribute DOMString longName;
  readonly attribute unsigned short mcc;
  readonly attribute unsigned short mnc;
  readonly attribute DOMString shortName;
  readonly attribute DOMString? state;
};

Properties

Name Type Description
longName string Long name of the network operator
mcc unsigned short Mobile Country Code (MCC) of the network operator
mnc unsigned short Mobile Network Code (MNC) of the network operator
shortName string Short name of the network operator
state string

Gives the state of this network operator.

Possible values are: available, connected, or forbidden

If the state of the network operator is unknown, this property will be null

Methods

None.

Specification

Not part of any specification

See also

  • {{ domxref("window.navigator.mozMobileConnection","navigator.mozMobileConnection") }}

Revision Source

<p>{{ domref() }}</p>
<p>{{ non-standard_header() }}</p>
<p>The <code>MozMobileNetworkInfo</code> interface allow to access information related to the network carrier. The {{domxref("window.navigator.mozMobileConnection","navigator.mozMobileConnection")}} uses it through its <code>voice.network</code> and <code>data.network</code> properties.</p>
<h2 id="Interface">Interface</h2>
<pre>
interface MozMobileNetworkInfo
{
&nbsp; readonly attribute DOMString longName;
&nbsp; readonly attribute unsigned short mcc;
&nbsp; readonly attribute unsigned short mnc;
&nbsp; readonly attribute DOMString shortName;
&nbsp; readonly attribute DOMString? state;
};</pre>
<h2 id="Properties">Properties</h2>
<table class="standard-table">
  <thead>
    <tr>
      <th scope="col">Name</th>
      <th scope="col">Type</th>
      <th scope="col">Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><code>longName</code></td>
      <td><code>string</code></td>
      <td>Long name of the network operator</td>
    </tr>
    <tr>
      <td><code>mcc</code></td>
      <td><code>unsigned short</code></td>
      <td><a href="http://en.wikipedia.org/wiki/Mobile_country_code" rel="external" title="http://en.wikipedia.org/wiki/Mobile_country_code">Mobile Country Code (MCC)</a> of the network operator</td>
    </tr>
    <tr>
      <td><code>mnc</code></td>
      <td><code>unsigned short</code></td>
      <td><a href="http://en.wikipedia.org/wiki/Mobile_country_code" rel="external" title="http://en.wikipedia.org/wiki/Mobile_country_code">Mobile Network Code (MNC)</a> of the network operator</td>
    </tr>
    <tr>
      <td><code>shortName</code></td>
      <td><code>string</code></td>
      <td>Short name of the network operator</td>
    </tr>
    <tr>
      <td><code>state</code></td>
      <td><code>string</code></td>
      <td>
        <p>Gives the state of this network operator.</p>
        <p>Possible values are: <code>available</code>, <code>connected</code>, or <code>forbidden</code></p>
        <p>If the state of the network operator is unknown, this property will be <code>null</code></p>
      </td>
    </tr>
  </tbody>
</table>
<h2 id="Methods">Methods</h2>
<p>None.</p>
<h2 id="Specification" name="Specification">Specification</h2>
<p>Not part of any specification</p>
<h2 id="See_also">See also</h2>
<ul>
  <li>{{ domxref("window.navigator.mozMobileConnection","navigator.mozMobileConnection") }}</li>
</ul>
Revert to this revision