aboutsummaryrefslogtreecommitdiff
path: root/files/fr/web/api/nodeiterator/whattoshow/index.html
diff options
context:
space:
mode:
authorjulieng <julien.gattelier@gmail.com>2021-10-02 17:20:14 +0200
committerSphinxKnight <SphinxKnight@users.noreply.github.com>2021-10-02 17:30:20 +0200
commitc05efa8d7ae464235cf83d7c0956e42dc6974103 (patch)
tree6ea911b2f2010f63a026de6bb7a1a51e7690a7e1 /files/fr/web/api/nodeiterator/whattoshow/index.html
parent13a5e017558b248ee1647d4a5825f183b51f09ad (diff)
downloadtranslated-content-c05efa8d7ae464235cf83d7c0956e42dc6974103.tar.gz
translated-content-c05efa8d7ae464235cf83d7c0956e42dc6974103.tar.bz2
translated-content-c05efa8d7ae464235cf83d7c0956e42dc6974103.zip
move *.html to *.md
Diffstat (limited to 'files/fr/web/api/nodeiterator/whattoshow/index.html')
-rw-r--r--files/fr/web/api/nodeiterator/whattoshow/index.html145
1 files changed, 0 insertions, 145 deletions
diff --git a/files/fr/web/api/nodeiterator/whattoshow/index.html b/files/fr/web/api/nodeiterator/whattoshow/index.html
deleted file mode 100644
index 216eee5ac5..0000000000
--- a/files/fr/web/api/nodeiterator/whattoshow/index.html
+++ /dev/null
@@ -1,145 +0,0 @@
----
-title: NodeIterator.whatToShow
-slug: Web/API/NodeIterator/whatToShow
-tags:
- - API
- - Arborescence
- - DOM
- - Itérateur
- - Noeuds
- - Propriétés
-translation_of: Web/API/NodeIterator/whatToShow
----
-<div>{{APIRef("DOM")}}</div>
-
-<p>La propriété en lecture seule <strong><code>NodeIterator.whatToShow</code></strong> est un <code>unsigned integer</code> (<em>entier non signé</em>) représentant un masque de bits désignant le type de noeuds qui doit être renvoyé par le {{domxref("NodeIterator")}}.</p>
-
-<h2 id="Syntax">Syntaxe</h2>
-
-<pre class="syntaxbox">var nodeTypes = <em>nodeIterator</em>.whatToShow;
-</pre>
-
-<p>Les valeurs pouvant être combinées pour former le masque de bits sont :</p>
-
-<table class="standard-table">
- <tbody>
- <tr>
- <td class="header">Constante</td>
- <td class="header">Valeur numérique</td>
- <td class="header">Description</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_ALL</code></td>
- <td><code>-1</code> (c'est la valeur numérique maximale du <code>unsigned long</code> (<em>non signé long</em>))</td>
- <td>Affiche tous les noeuds.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_ATTRIBUTE</code> {{deprecated_inline}}</td>
- <td><code>2</code></td>
- <td>Affiche l'attribut {{domxref("Attr")}} des noeuds. Cela n'a de sens que lors de la création d'un {{domxref("TreeWalker")}} avec un noeud {{domxref("Attr")}} comme racine ; dans ce cas, cela signifie que le nœud d'attribut apparaîtra dans la première position de l'itération ou de la traversée. Comme les attributs ne sont jamais des enfants d'autres nœuds, ils n'apparaissent pas lors de la traversée de l'arbre du document.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_CDATA_SECTION</code> {{deprecated_inline}}</td>
- <td><code>8</code></td>
- <td>Affiche les noeuds {{domxref("CDATASection")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_COMMENT</code></td>
- <td><code>128</code></td>
- <td>Affiche les noeuds {{domxref("Comment")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_DOCUMENT</code></td>
- <td><code>256</code></td>
- <td>Affiche les noeuds {{domxref("Document")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_DOCUMENT_FRAGMENT</code></td>
- <td><code>1024</code></td>
- <td>Affiche les noeuds {{domxref("DocumentFragment")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_DOCUMENT_TYPE</code></td>
- <td><code>512</code></td>
- <td>Affiche les noeuds {{domxref("DocumentType")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_ELEMENT</code></td>
- <td><code>1</code></td>
- <td>Affiche les noeuds {{domxref("Element")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_ENTITY</code> {{deprecated_inline}}</td>
- <td><code>32</code></td>
- <td>Affiche les noeuds {{domxref("Entity")}}. Cela n'a de sens que lors de la création d'un {{domxref("TreeWalker")}} avec un noeud {{ domxref("Entity") }} comme racine ; dans ce cas, il signifie que le noeud d'entité {{domxref("Entity") }} apparaîtra à la première position de la traversée. Étant donné que les entités ne font pas partie de l'arborescence du document, elles n'apparaissent pas lors de la traversée de l'arborescence du document.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_ENTITY_REFERENCE</code> {{deprecated_inline}}</td>
- <td><code>16</code></td>
- <td>Affiche les noeuds {{domxref("EntityReference")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_NOTATION</code> {{deprecated_inline}}</td>
- <td><code>2048</code></td>
- <td>Affiche les noeuds {{domxref("Notation")}}. Cela n'a de sens que lors de la création d'un {{domxref("TreeWalker")}} avec un noeud {{domxref("Notation")}} comme racine ; dans ce cas, il signifie que le noeud {{domxref("Notation")}} apparaîtra à la première position de la traversée. Étant donné que les entités ne font pas partie de l'arborescence du document, elles n'apparaissent pas lors de la traversée de l'arborescence du document.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_PROCESSING_INSTRUCTION</code></td>
- <td><code>64</code></td>
- <td>Affiche les noeuds {{domxref("ProcessingInstruction")}}.</td>
- </tr>
- <tr>
- <td><code>NodeFilter.SHOW_TEXT</code></td>
- <td><code>4</code></td>
- <td>Affiche les noeuds {{domxref("Text")}}.</td>
- </tr>
- </tbody>
-</table>
-
-<h2 id="Example">Exemple</h2>
-
-<pre class="brush: js">var nodeIterator = document.createNodeIterator(
- document.body,
- NodeFilter.SHOW_ELEMENT + NodeFilter.SHOW_COMMENT + NodeFilter.SHOW_TEXT,
- { acceptNode: function(node) { return NodeFilter.FILTER_ACCEPT; } },
- false
-);
-if( (nodeIterator.whatToShow == NodeFilter.SHOW_ALL) ||
- (nodeIterator.whatToShow % (NodeFilter.SHOW_COMMENT*2)) &gt;= NodeFilter.SHOW_COMMENT) {
- // nodeIterator affichera les commentaires
-}
-</pre>
-
-<h2 id="Specification">Spécifications</h2>
-
-<table class="standard-table">
- <tbody>
- <tr>
- <th scope="col">Spécification</th>
- <th scope="col">Statut</th>
- <th scope="col">Commentaire</th>
- </tr>
- <tr>
- <td>{{SpecName('DOM WHATWG', '#dom-nodeiterator-whattoshow', 'NodeIterator.whatToShow')}}</td>
- <td>{{Spec2('DOM WHATWG')}}</td>
- <td>Pas de changement depuis {{SpecName('DOM2 Traversal_Range')}}.</td>
- </tr>
- <tr>
- <td>{{SpecName('DOM2 Traversal_Range', 'traversal.html#Traversal-NodeIterator-whatToShow', 'NodeIterator.whatToShow')}}</td>
- <td>{{Spec2('DOM2 Traversal_Range')}}</td>
- <td>Définitioni initiale.</td>
- </tr>
- </tbody>
-</table>
-
-<h2 id="Compatibilité_des_navigateurs">Compatibilité des navigateurs</h2>
-
-
-
-<p>{{Compat("api.NodeIterator.whatToShow")}}</p>
-
-<h2 id="Voir_aussi">Voir aussi</h2>
-
-<ul>
- <li>L'interface à laquelle cette propriété appartient : {{domxref("NodeIterator")}}.</li>
-</ul>