discovery-api/Overview.html
author Rich Tibbett <richt@opera.com>
Thu, 05 Sep 2013 15:53:34 +0200
changeset 453 07345c55f11f
parent 448 865b6f93faac
child 480 f3ea6558ffe1
permissions -rw-r--r--
Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
     1
<!DOCTYPE html>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
     2
<html lang="en"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
     3
      dir="ltr"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
     4
      typeof="bibo:Document"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
     5
      about=""
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
     6
      property="dcterms:language"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
     7
      content="en">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
     8
  <head>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
     9
    <title>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
    10
      Network Service Discovery
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
    11
    </title>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    12
    <meta http-equiv="Content-Type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    13
          content="text/html; charset=utf-8">
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    14
    <style>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    15
/* Custom ReSpec CSS (by Rich Tibbett) */
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    16
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    17
     /* Add better spacing to sections */
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    18
     section, .section { margin-bottom: 2em; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    19
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    20
     /* Add addition spacing to <ol> and <ul> for rule definition */
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    21
     ol.rule li, ul.rule li { padding:0.6em; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    22
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    23
     pre.widl { border: solid thin; background: #EEEEEE; color: black; padding: 0.5em 1em; position: relative; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    24
     pre.widl :link, pre.widl :visited { color: #000; background: transparent; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    25
     pre.widl:before { content: "IDL"; font: bold small sans-serif; padding: 0.5em; background: white; position: absolute; top: 0; margin: -1px 0 0 -4em; width: 1.5em; border: thin solid; border-radius: 0 0 0 0.5em }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    26
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    27
     div.example { border: solid thin black; background: #FFFFF0; color: black; padding: 0.5em 1em; position: relative; margin: 1em 0 1em 4.6em; width: auto; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    28
     div.example:before { content: "EXAMPLE"; font: bold small sans-serif; padding: 0.5em; background: white; color: black; position: absolute; top: 0; margin: -1px 0 0 -7.6em; width: 5em; border: thin solid black; border-radius: 0 0 0 0.5em }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    29
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    30
     dl.domintro { color: green; margin: 2em 0 2em 2em; padding: 0.5em 1em; border: none; background: #DDFFDD; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    31
     hr + dl.domintro, div.impl + dl.domintro { margin-top: 2.5em; margin-bottom: 1.5em; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    32
     dl.domintro dt, dl.domintro dt * { color: black; text-decoration: none; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    33
     dl.domintro dd { margin: 0.5em 0 1em 2em; padding: 0; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    34
     dl.domintro dd p { margin: 0.5em 0; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    35
     dl.domintro code {font-size: inherit; font-style: italic; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    36
     dl.domintro:before { display: table; margin: -1em -0.5em 0.5em auto; width: auto; content: 'This box is non-normative. Implementation requirements are given below this box.'; color: red; border: solid 2px; background: white; padding: 0 0.25em; font-size:0.8em; }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    37
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    38
     table { border-collapse:collapse; border-style:hidden hidden none hidden }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    39
     table thead { border-bottom:solid }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    40
     table tbody th:first-child { border-left:solid }
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    41
     table td, table th { border-left:solid; border-right:solid; border-bottom:solid thin; vertical-align:top; padding:0.2em }
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    42
    </style>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    43
    <style>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    44
/*****************************************************************
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    45
    * ReSpec 3 CSS
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    46
    * Robin Berjon - http://berjon.com/
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    47
    *****************************************************************/
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
    48
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    49
    /* --- INLINES --- */
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    50
    em.rfc2119 {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    51
    text-transform:     lowercase;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    52
    font-variant:       small-caps;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    53
    font-style:         normal;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    54
    color:              #900;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    55
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    56
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    57
    h1 acronym, h2 acronym, h3 acronym, h4 acronym, h5 acronym, h6 acronym, a acronym,
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    58
    h1 abbr, h2 abbr, h3 abbr, h4 abbr, h5 abbr, h6 abbr, a abbr {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    59
    border: none;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    60
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    61
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    62
    dfn {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    63
    font-weight:    bold;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    64
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    65
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    66
    a.internalDFN {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    67
    color:  inherit;
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
    68
    border-bottom:  1px solid #99c;
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    69
    text-decoration:    none;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    70
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    71
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    72
    a.externalDFN {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    73
    color:  inherit;
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
    74
    border-bottom:  1px dotted #ccc;
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    75
    text-decoration:    none;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    76
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    77
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    78
    a.bibref {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    79
    text-decoration:    none;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    80
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    81
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    82
    cite .bibref {
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    83
    font-style: normal;
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    84
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    85
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    86
    code {
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    87
    color:  #ff4500;
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    88
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    89
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    90
    /* --- TOC --- */
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    91
    .toc a, .tof a {
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    92
    text-decoration:    none;
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    93
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    94
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    95
    a .secno, a .figno {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
    96
    color:  #000;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    97
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
    98
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
    99
    ul.tof, ol.tof {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   100
    list-style: none outside none;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   101
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   102
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   103
    .caption {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   104
    margin-top: 0.5em;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   105
    font-style:   italic;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   106
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   107
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   108
    /* --- TABLE --- */
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   109
    table.simple {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   110
    border-spacing: 0;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   111
    border-collapse:    collapse;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   112
    border-bottom:  3px solid #005a9c;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   113
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   114
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   115
    .simple th {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   116
    background: #005a9c;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   117
    color:  #fff;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   118
    padding:    3px 5px;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   119
    text-align: left;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   120
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   121
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   122
    .simple th[scope="row"] {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   123
    background: inherit;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   124
    color:  inherit;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   125
    border-top: 1px solid #ddd;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   126
    }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   127
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   128
    .simple td {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   129
    padding:    3px 10px;
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   130
    border-top: 1px solid #ddd;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   131
    }
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   132
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   133
    .simple tr:nth-child(even) {
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   134
    background: #f0f6ff;
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   135
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   136
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   137
    /* --- DL --- */
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   138
    .section dd > p:first-child {
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   139
    margin-top: 0;
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   140
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   141
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   142
    .section dd > p:last-child {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   143
    margin-bottom: 0;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   144
    }
333
5e7aecddf47a Compile editor's draft
Rich Tibbett <richt@opera.com>
parents: 254
diff changeset
   145
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   146
    .section dd {
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   147
    margin-bottom:  1em;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   148
    }
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   149
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   150
    .section dl.attrs dd, .section dl.eldef dd {
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   151
    margin-bottom:  0;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   152
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   153
    </style>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   154
    <style>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   155
/* --- ISSUES/NOTES --- */
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   156
    div.issue-title, div.note-title {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   157
    padding-right:  1em;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   158
    min-width: 7.5em;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   159
    color: #b9ab2d;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   160
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   161
    div.issue-title { color: #e05252; }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   162
    div.note-title { color: #2b2; }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   163
    div.issue-title span, div.note-title span {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   164
    text-transform: uppercase;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   165
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   166
    div.note, div.issue {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   167
    margin-top: 1em;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   168
    margin-bottom: 1em;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   169
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   170
    .note > p:first-child, .issue > p:first-child { margin-top: 0 }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   171
    .issue, .note {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   172
    padding: .5em;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   173
    border-left-width: .5em;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   174
    border-left-style: solid;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   175
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   176
    div.issue, div.note {
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   177
    padding: 1em 1.2em 0.5em;
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   178
    margin: 1em 0;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   179
    position: relative;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   180
    clear: both;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   181
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   182
    span.note, span.issue { padding: .1em .5em .15em; }
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   183
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   184
    .issue {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   185
    border-color: #e05252;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   186
    background: #fbe9e9;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   187
    }
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   188
    .note {
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   189
    border-color: #52e052;
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   190
    background: #e9fbe9;
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   191
    }
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   192
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   193
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   194
    </style>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   195
    <style>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   196
/* HIGHLIGHTS */
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   197
    code.prettyprint {
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   198
    color:  inherit;
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   199
    }
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   200
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   201
    /* this from google-code-prettify */
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   202
    .pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee}
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   203
    </style>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   204
    <link rel="stylesheet"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   205
          href="https://www.w3.org/StyleSheets/TR/W3C-ED">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   206
  </head>
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   207
  <body class="h-entry"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   208
        role="document"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   209
        id="respecDocument">
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   210
    <div class="head"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   211
         role="contentinfo"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   212
         id="respecHeader">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   213
      <p>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   214
        <a href="http://www.w3.org/"><img width="72"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   215
             height="48"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   216
             src="https://www.w3.org/Icons/w3c_home"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   217
             alt="W3C"></a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   218
      </p>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   219
      <h1 class="title p-name"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   220
          id="title"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   221
          property="dcterms:title">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   222
        Network Service Discovery
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   223
      </h1>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   224
      <h2 property="dcterms:issued"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   225
          datatype="xsd:dateTime"
453
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   226
          content="2013-09-05T11:58:47.000Z"
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   227
          id="w3c-editor-s-draft-05-september-2013">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   228
        <abbr title="World Wide Web Consortium">W3C</abbr> Editor's Draft <time class="dt-published"
453
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   229
            datetime="2013-09-05">05 September 2013</time>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   230
      </h2>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   231
      <dl>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   232
        <dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   233
          This version:
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   234
        </dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   235
        <dd>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   236
          <a class="u-url"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   237
              href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   238
              "http://dvcs.w3.org/hg/dap/raw-file/tip/discovery-api/Overview.html">http://dvcs.w3.org/hg/dap/raw-file/tip/discovery-api/Overview.html</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   239
        </dd>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   240
        <dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   241
          Latest published version:
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   242
        </dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   243
        <dd>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   244
          <a href="http://www.w3.org/TR/discovery-api/">http://www.w3.org/TR/discovery-api/</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   245
        </dd>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   246
        <dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   247
          Latest editor's draft:
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   248
        </dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   249
        <dd>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   250
          <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   251
          "http://dvcs.w3.org/hg/dap/raw-file/tip/discovery-api/Overview.html">http://dvcs.w3.org/hg/dap/raw-file/tip/discovery-api/Overview.html</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   252
        </dd>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   253
        <dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   254
          Editor:
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   255
        </dt>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   256
        <dd class="p-author h-card vcard"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   257
            rel="bibo:editor"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   258
            inlist="">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   259
          <span typeof="foaf:Person"><span property="foaf:name"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   260
                class="p-name fn">Rich Tibbett</span>, <a rel="foaf:workplaceHomepage"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   261
             class="p-org org h-org h-card"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   262
             href="http://opera.com/">Opera Software ASA</a></span>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   263
        </dd>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   264
      </dl>
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   265
      <p class="copyright">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   266
        <a href="http://www.w3.org/Consortium/Legal/ipr-notice#Copyright">Copyright</a> © 2013 <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   267
        "http://www.w3.org/"><abbr title="World Wide Web Consortium">W3C</abbr></a><sup>®</sup> (<a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   268
        "http://www.csail.mit.edu/"><abbr title="Massachusetts Institute of Technology">MIT</abbr></a>, <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   269
        "http://www.ercim.eu/"><abbr title=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   270
        "European Research Consortium for Informatics and Mathematics">ERCIM</abbr></a>, <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   271
        "http://www.keio.ac.jp/">Keio</a>, <a href="http://ev.buaa.edu.cn/">Beihang</a>), All Rights Reserved.
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   272
        <abbr title="World Wide Web Consortium">W3C</abbr> <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   273
        "http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer">liability</a>, <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   274
        "http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks">trademark</a> and <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   275
        "http://www.w3.org/Consortium/Legal/copyright-documents">document use</a> rules apply.
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   276
      </p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   277
      <hr>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   278
    </div>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   279
    <section id="abstract"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   280
             class="introductory"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   281
             property="dcterms:abstract"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   282
             datatype=""
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   283
             typeof="bibo:Chapter"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   284
             resource="#abstract"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   285
             rel="bibo:chapter">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   286
      <h2 aria-level="1"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   287
          role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   288
          id="h2_abstract">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   289
        Abstract
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   290
      </h2>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   291
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   292
        This specification defines a mechanism for an HTML document to discover and subsequently communicate with
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   293
        <abbr title="Hypertext Transfer Protocol">HTTP</abbr>-based services advertised via common discovery protocols
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   294
        within the current network.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   295
      </p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   296
    </section>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   297
    <section id="toc">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   298
      <h2 class="introductory"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   299
          aria-level="1"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   300
          role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   301
          id="h2_toc">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   302
        Table of Contents
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   303
      </h2>
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   304
      <ul class="toc"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   305
          role="directory"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   306
          id="respecContents">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   307
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   308
          <a href="#introduction"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   309
              class="tocxref"><span class="secno">1.</span> Introduction</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   310
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   311
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   312
          <a href="#conformance"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   313
              class="tocxref"><span class="secno">2.</span> Conformance</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   314
          <ul class="toc">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   315
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   316
              <a href="#dependencies"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   317
                  class="tocxref"><span class="secno">2.1</span> Dependencies</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   318
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   319
          </ul>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   320
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   321
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   322
          <a href="#terminology"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   323
              class="tocxref"><span class="secno">3.</span> Terminology</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   324
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   325
        <li class="tocline">
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   326
          <a href="#security-and-privacy-considerations"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   327
              class="tocxref"><span class="secno">4.</span> Security and privacy considerations</a>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   328
          <ul class="toc">
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   329
            <li class="tocline">
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   330
              <a href="#privacy-considerations-for-api-implementations"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   331
                  class="tocxref"><span class="secno">4.1</span> Privacy considerations for <abbr title=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   332
                  "Application Programming Interface">API</abbr> implementations</a>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   333
            </li>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   334
            <li class="tocline">
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   335
              <a href="#additional-api-implementation-considerations"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   336
                  class="tocxref"><span class="secno">4.2</span> Additional <abbr title=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   337
                  "Application Programming Interface">API</abbr> implementation considerations</a>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   338
            </li>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   339
          </ul>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   340
        </li>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   341
        <li class="tocline">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   342
          <a href="#requesting-networked-services"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   343
              class="tocxref"><span class="secno">5.</span> Requesting networked services</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   344
          <ul class="toc">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   345
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   346
              <a href="#methods"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   347
                  class="tocxref"><span class="secno">5.1</span> Methods</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   348
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   349
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   350
              <a href="#error-handling"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   351
                  class="tocxref"><span class="secno">5.2</span> Error Handling</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   352
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   353
          </ul>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   354
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   355
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   356
          <a href="#obtaining-networked-services"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   357
              class="tocxref"><span class="secno">6.</span> Obtaining networked services</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   358
          <ul class="toc">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   359
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   360
              <a href="#attributes"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   361
                  class="tocxref"><span class="secno">6.1</span> Attributes</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   362
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   363
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   364
              <a href="#methods-1"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   365
                  class="tocxref"><span class="secno">6.2</span> Methods</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   366
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   367
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   368
              <a href="#events"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   369
                  class="tocxref"><span class="secno">6.3</span> Events</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   370
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   371
          </ul>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   372
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   373
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   374
          <a href="#communicating-with-a-networked-service"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   375
              class="tocxref"><span class="secno">7.</span> Communicating with a networked service</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   376
          <ul class="toc">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   377
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   378
              <a href="#attributes-1"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   379
                  class="tocxref"><span class="secno">7.1</span> Attributes</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   380
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   381
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   382
              <a href="#states"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   383
                  class="tocxref"><span class="secno">7.2</span> States</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   384
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   385
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   386
              <a href="#events-1"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   387
                  class="tocxref"><span class="secno">7.3</span> Events</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   388
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   389
          </ul>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   390
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   391
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   392
          <a href="#service-discovery"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   393
              class="tocxref"><span class="secno">8.</span> Service Discovery</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   394
          <ul class="toc">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   395
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   396
              <a href="#zeroconf-mdns-dns-sd"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   397
                  class="tocxref"><span class="secno">8.1</span> Zeroconf (<abbr title="Multicast DNS">mDNS</abbr> +
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   398
                  <abbr title="Domain Name System">DNS</abbr>-<abbr title="Service Discovery">SD</abbr>)</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   399
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   400
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   401
              <a href="#simple-service-discovery-protocol-ssdp"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   402
                  class="tocxref"><span class="secno">8.2</span> Simple Service Discovery Protocol (<abbr title=
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   403
                  "Simple Service Discovery Protocol">SSDP</abbr>)</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   404
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   405
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   406
              <a href="#discovery-and-launch-protocol-dial"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   407
                  class="tocxref"><span class="secno">8.3</span> Discovery and Launch Protocol (<abbr title=
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   408
                  "Discovery and Launch Protocol">DIAL</abbr>)</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   409
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   410
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   411
              <a href="#network-topology-monitoring"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   412
                  class="tocxref"><span class="secno">8.4</span> Network Topology Monitoring</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   413
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   414
          </ul>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   415
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   416
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   417
          <a href="#events-summary"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   418
              class="tocxref"><span class="secno">9.</span> Events Summary</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   419
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   420
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   421
          <a href="#garbage-collection"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   422
              class="tocxref"><span class="secno">10.</span> Garbage collection</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   423
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   424
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   425
          <a href="#use-cases-and-requirements"
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   426
              class="tocxref"><span class="secno">11.</span> Use Cases and Requirements</a>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   427
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   428
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   429
          <a href="#examples"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   430
              class="tocxref"><span class="secno">A.</span> Examples</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   431
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   432
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   433
          <a href="#acknowledgements"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   434
              class="tocxref"><span class="secno">B.</span> Acknowledgements</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   435
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   436
        <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   437
          <a href="#references"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   438
              class="tocxref"><span class="secno">C.</span> References</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   439
          <ul class="toc">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   440
            <li class="tocline">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   441
              <a href="#normative-references"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   442
                  class="tocxref"><span class="secno">C.1</span> Normative references</a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   443
            </li>
453
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   444
            <li class="tocline">
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   445
              <a href="#informative-references"
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   446
                  class="tocxref"><span class="secno">C.2</span> Informative references</a>
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   447
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   448
          </ul>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   449
        </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   450
      </ul>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   451
    </section>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   452
    <section class="informative"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   453
             id="introduction">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   454
      <h2 aria-level="1"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   455
          role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   456
          id="h2_introduction">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   457
        <span class="secno">1.</span> Introduction
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   458
      </h2>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   459
      <p>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   460
        <em>This section is non-normative.</em>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   461
      </p>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   462
      <p>
453
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   463
        This specification defines the <a href="#navigatornetworkservice"><code>NavigatorNetworkService</code></a>
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   464
        interface to enable Web pages to connect and communicate with Local-networked Services provided over
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   465
        <abbr title="Hypertext Transfer Protocol">HTTP</abbr>. This enables access to services and content provided by
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   466
        home network devices, including the discovery and playback of content available to those devices, both from
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   467
        services such as traditional broadcast media and internet based services as well as local services. Initial
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   468
        design goals and requirements provided by the <a href="http://www.w3.org/2011/webtv/"><abbr title=
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   469
        "World Wide Web Consortium">W3C</abbr> Web &amp; TV interest group</a> are documented in [<cite><a class=
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   470
        "bibref"
07345c55f11f Fix [DAP-ISSUE-147]: Reference 'Requirements for Home Networking Scenarios' in Introduction
Rich Tibbett <richt@opera.com>
parents: 448
diff changeset
   471
           href="#bib-hnreq">hnreq</a></cite>].
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   472
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   473
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   474
        Using this <abbr title="Application Programming Interface">API</abbr> consists of requesting a well-known
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   475
        service type, known by developers and advertised by Local-networked Devices. User authorization, where the user
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   476
        connects the web page to discovered services, is expected before the web page is able to interact with any
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   477
        Local-networked Services.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   478
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   479
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   480
        A web page creates a request to obtain connectivity to services running in the network by specifying a
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   481
        well-known discovery service type that it wishes to interact with.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   482
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   483
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   484
        The user agent, having captured all advertised services on the network from the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   485
        "#dfn-service-discovery-mechanisms"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   486
           class="internalDFN">service discovery mechanisms</a> included in this recommendation, attempts to match the
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   487
           requested service type to a discovered service according to the processing described herein.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   488
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   489
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   490
        If a service connectivity request is successful then the Web page is provided with a promise-based success
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   491
        callback with the all necessary information to communicate with the authorized Local-networked Service. If the
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   492
        request fails then the Web page will receive a promise-based error callback containing an error string
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   493
        describing the cause of Local-networked Service connectivity failure.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   494
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   495
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   496
        Once connected to a Local-networked Service the Web page can send requests and receive responses to the
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   497
        Local-networked Service via the messaging format and appropriate channel inferred from the service type
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   498
        authorized via the provided <abbr title="Application Programming Interface">API</abbr>. The Web page, once
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   499
        connected, can also receive service-pushed events, in the messaging format supported by the Local-networked
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   500
        Device, if such event subscription functionality is provided by the connected Local-networked Service.
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   501
      </p>
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   502
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   503
        Services available within the local network can connect and disconnect at different times during the execution
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   504
        of a web page. The user agent can inform a web page when the state of networked services matching any of the
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   505
        requested valid service types change. Web pages can use this information to enable in-page experiences for
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   506
        communicating the state of networked services with the ability to change the particular service or set of
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   507
        services the page is connected to (by re-invoking the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   508
        "#dom-navigator-getnetworkservices"><code>getNetworkServices()</code></a> method defined herein).
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   509
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   510
      <div class="example">
191
5e0da09685f7 Discovery API updates following feedback from http://lists.w3.org/Archives/Public/public-device-apis/2012Aug/0016.html
Rich Tibbett <richt@opera.com>
parents: 180
diff changeset
   511
        <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   512
          Example of requesting a <abbr title="Domain Name System">DNS</abbr>-<abbr title="Service Discovery">SD</abbr>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   513
          advertised service:
191
5e0da09685f7 Discovery API updates following feedback from http://lists.w3.org/Archives/Public/public-device-apis/2012Aug/0016.html
Rich Tibbett <richt@opera.com>
parents: 180
diff changeset
   514
        </p>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   515
        <hr>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   516
        <pre class="highlight prettyprint">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   517
<span class="kwd">function</span><span class="pln"> showServices</span><span class="pun">(</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   518
"pln"> services </span><span class="pun">)</span><span class="pln"> </span><span class="pun">{</span><span class="pln">
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   519
  </span><span class="com">// Show a list of all the services provided to the web page</span><span class="pln">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   520
  </span><span class="kwd">for</span><span class="pun">(</span><span class="kwd">var</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   521
"pln"> i </span><span class="pun">=</span><span class="pln"> </span><span class="lit">0</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   522
"pun">,</span><span class="pln"> l </span><span class="pun">=</span><span class="pln"> services</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   523
"pun">.</span><span class="pln">length</span><span class="pun">;</span><span class="pln"> i </span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   524
"pun">&lt;</span><span class="pln"> l</span><span class="pun">;</span><span class="pln"> i</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   525
"pun">++)</span><span class="pln"> console</span><span class="pun">.</span><span class="pln">log</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   526
"pun">(</span><span class="pln"> services</span><span class="pun">[</span><span class="pln">i</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   527
"pun">].</span><span class="pln">name </span><span class="pun">);</span><span class="pln">
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   528
</span><span class="pun">}</span><span class="pln">
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   529
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   530
navigator</span><span class="pun">.</span><span class="pln">getNetworkServices</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   531
"pun">(</span><span class="str">'zeroconf:_boxee-jsonrpc._tcp'</span><span class="pun">).</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   532
"kwd">then</span><span class="pun">(</span><span class="pln">showServices</span><span class="pun">);</span>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   533
</pre>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   534
      </div>
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   535
      <div class="example">
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   536
        <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   537
          Example of requesting a UPnP advertised service, also handling error conditions:
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   538
        </p>
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   539
        <hr>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   540
        <pre class="highlight prettyprint">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   541
<span class="kwd">function</span><span class="pln"> showServices</span><span class="pun">(</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   542
"pln"> services </span><span class="pun">)</span><span class="pln"> </span><span class="pun">{</span><span class="pln">
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   543
  </span><span class="com">// Show a list of all the services provided to the web page</span><span class="pln">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   544
  </span><span class="kwd">for</span><span class="pun">(</span><span class="kwd">var</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   545
"pln"> i </span><span class="pun">=</span><span class="pln"> </span><span class="lit">0</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   546
"pun">,</span><span class="pln"> l </span><span class="pun">=</span><span class="pln"> services</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   547
"pun">.</span><span class="pln">length</span><span class="pun">;</span><span class="pln"> i </span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   548
"pun">&lt;</span><span class="pln"> l</span><span class="pun">;</span><span class="pln"> i</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   549
"pun">++)</span><span class="pln"> console</span><span class="pun">.</span><span class="pln">log</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   550
"pun">(</span><span class="pln"> services</span><span class="pun">[</span><span class="pln">i</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   551
"pun">].</span><span class="pln">name </span><span class="pun">);</span><span class="pln">
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   552
</span><span class="pun">}</span><span class="pln">
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   553
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   554
</span><span class="kwd">function</span><span class="pln"> error</span><span class="pun">(</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   555
"pln"> e </span><span class="pun">)</span><span class="pln"> </span><span class="pun">{</span><span class="pln">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   556
  console</span><span class="pun">.</span><span class="pln">log</span><span class="pun">(</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   557
"pln"> </span><span class="str">"Error occurred: "</span><span class="pln"> </span><span class=
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   558
"pun">+</span><span class="pln"> e</span><span class="pun">.</span><span class="pln">name </span><span class=
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   559
"pun">);</span><span class="pln">
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   560
</span><span class="pun">}</span><span class="pln">
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   561
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   562
navigator</span><span class="pun">.</span><span class="pln">getNetworkServices</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   563
"pun">(</span><span class="str">'upnp:urn:schemas-upnp-org:service:ContentDirectory:1'</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   564
"pun">).</span><span class="kwd">then</span><span class="pun">(</span><span class="pln">showServices</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   565
"pun">,</span><span class="pln"> error</span><span class="pun">);</span>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   566
</pre>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   567
      </div>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   568
      <div class="example">
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   569
        <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   570
          Example of requesting either a <abbr title="Domain Name System">DNS</abbr>-<abbr title=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   571
          "Service Discovery">SD</abbr> or UPnP advertised service:
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   572
        </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   573
        <hr>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   574
        <pre class="highlight prettyprint">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   575
<span class="kwd">function</span><span class="pln"> showServices</span><span class="pun">(</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   576
"pln"> services </span><span class="pun">)</span><span class="pln"> </span><span class="pun">{</span><span class="pln">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   577
  </span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   578
"com">// Show a list of all the services provided to the web page (+ service type)</span><span class="pln">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   579
  </span><span class="kwd">for</span><span class="pun">(</span><span class="kwd">var</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   580
"pln"> i </span><span class="pun">=</span><span class="pln"> </span><span class="lit">0</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   581
"pun">,</span><span class="pln"> l </span><span class="pun">=</span><span class="pln"> services</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   582
"pun">.</span><span class="pln">length</span><span class="pun">;</span><span class="pln"> i </span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   583
"pun">&lt;</span><span class="pln"> l</span><span class="pun">;</span><span class="pln"> i</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   584
"pun">++)</span><span class="pln">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   585
     console</span><span class="pun">.</span><span class="pln">log</span><span class="pun">(</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   586
"pln"> services</span><span class="pun">[</span><span class="pln">i</span><span class="pun">].</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   587
"pln">name </span><span class="pun">+</span><span class="pln"> </span><span class="str">'('</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   588
"pln"> </span><span class="pun">+</span><span class="pln"> services</span><span class="pun">[</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   589
"pln">i</span><span class="pun">].</span><span class="pln">type </span><span class="pun">+</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   590
"pln"> </span><span class="str">')'</span><span class="pln"> </span><span class="pun">);</span><span class="pln">
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   591
</span><span class="pun">}</span><span class="pln">
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   592
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   593
navigator</span><span class="pun">.</span><span class="pln">getNetworkServices</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   594
"pun">([</span><span class="pln">
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   595
  </span><span class="str">'zeroconf:_boxee-jsonrpc._tcp'</span><span class="pun">,</span><span class="pln">
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   596
  </span><span class="str">'upnp:urn:schemas-upnp-org:service:ContentDirectory:1'</span><span class="pln">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   597
</span><span class="pun">]).</span><span class="kwd">then</span><span class="pun">(</span><span class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   598
"pln">showServices</span><span class="pun">);</span>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   599
</pre>
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   600
      </div>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   601
      <p>
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   602
        For more detailed examples, including examples of communicating with obtained networked services, see the
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   603
        <a href="#examples">Examples</a> section.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   604
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   605
    </section>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   606
    <section id="conformance"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   607
             typeof="bibo:Chapter"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   608
             resource="#conformance"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   609
             rel="bibo:chapter">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   610
      <h2 aria-level="1"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   611
          role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   612
          id="h2_conformance">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   613
        <span class="secno">2.</span> Conformance
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   614
      </h2>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   615
      <p>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   616
        As well as sections marked as non-normative, all authoring guidelines, diagrams, examples, and notes in this
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   617
        specification are non-normative. Everything else in this specification is normative.
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   618
      </p>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   619
      <p>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   620
        The key words <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   621
           title="MUST">MUST</em>, <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   622
           title="MUST NOT">MUST NOT</em>, <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   623
           title="REQUIRED">REQUIRED</em>, <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   624
           title="SHOULD">SHOULD</em>, <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   625
           title="SHOULD NOT">SHOULD NOT</em>, <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   626
           title="RECOMMENDED">RECOMMENDED</em>, <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   627
           title="MAY">MAY</em>, and <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   628
           title="OPTIONAL">OPTIONAL</em> in this specification are to be interpreted as described in [<cite><a class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   629
           "bibref"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   630
           href="#bib-RFC2119">RFC2119</a></cite>].
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   631
      </p>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   632
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   633
        Requirements phrased in the imperative as part of algorithms (such as "strip any leading space characters" or
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   634
        "return false and abort these steps") are to be interpreted with the meaning of the key word ("must", "should",
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   635
        "may", etc) used in introducing the algorithm.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   636
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   637
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   638
        Some conformance requirements are phrased as requirements on attributes, methods or objects. Such requirements
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   639
        are to be interpreted as requirements on user agents.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   640
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   641
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   642
        Conformance requirements phrased as algorithms or specific steps <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   643
           title="MAY">MAY</em> be implemented in any manner, so long as the end result is equivalent. (In particular,
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   644
           the algorithms defined in this specification are intended to be easy to follow, and not intended to be
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   645
           performant.)
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   646
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   647
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   648
        The only conformance class defined by this specification is a <dfn id="dfn-user-agent">user agent</dfn>.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   649
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   650
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   651
        User agents <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   652
           title="MAY">MAY</em> impose implementation-specific limits on otherwise unconstrained inputs, e.g. to
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   653
           prevent denial of service attacks, to guard against running out of memory, or to work around
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   654
           platform-specific limitations.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   655
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   656
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   657
        When support for a feature is disabled (e.g. as an emergency measure to mitigate a security problem, or to aid
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   658
        in development, or for performance reasons), user agents <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   659
           title="MUST">MUST</em> act as if they had no support for the feature whatsoever, and as if the feature was
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   660
           not mentioned in this specification. For example, if a particular feature is accessed via an attribute in a
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   661
           Web IDL interface, the attribute itself would be omitted from the objects that implement that interface -
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   662
           leaving the attribute on the object but making it return null or throw an exception is insufficient.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   663
      </p>
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   664
      <section id="dependencies">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   665
        <h3 aria-level="2"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   666
            role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   667
            id="h3_dependencies">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   668
          <span class="secno">2.1</span> Dependencies
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   669
        </h3>This specification relies on several other underlying specifications.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   670
        <dl>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   671
          <dt>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   672
            HTML
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   673
          </dt>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   674
          <dd>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   675
            Many fundamental concepts from HTML are used by this specification. [<cite><a class="bibref"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   676
               href="#bib-HTML5">HTML5</a></cite>]
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   677
          </dd>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   678
          <dt>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   679
            WebIDL
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   680
          </dt>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   681
          <dd>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   682
            The IDL blocks in this specification use the semantics of the WebIDL specification. [<cite><a class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   683
            "bibref"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   684
               href="#bib-WEBIDL">WEBIDL</a></cite>]
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   685
          </dd>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   686
        </dl>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   687
      </section>
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   688
    </section>
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   689
    <section id="terminology">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   690
      <h2 aria-level="1"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   691
          role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   692
          id="h2_terminology">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   693
        <span class="secno">3.</span> Terminology
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   694
      </h2>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   695
      <p>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   696
        The construction "a <code>Foo</code> object", where <code>Foo</code> is actually an interface, is sometimes
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   697
        used instead of the more accurate "an object implementing the interface <code>Foo</code>".
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   698
      </p>
230
3c13dc93cfb1 Re-write of Section 7: Service Discovery according to feedback @ http://lists.w3.org/Archives/Public/public-device-apis/2012Aug/0017.html
Rich Tibbett <richt@opera.com>
parents: 216
diff changeset
   699
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   700
        The term DOM is used to refer to the <abbr title="Application Programming Interface">API</abbr> set made
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   701
        available to scripts in Web applications, and does not necessarily imply the existence of an actual
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   702
        <code>Document</code> object or of any other <code>Node</code> objects as defined in the DOM Core
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   703
        specifications. [<cite><a class="bibref"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   704
           href="#bib-DOM4">DOM4</a></cite>]
230
3c13dc93cfb1 Re-write of Section 7: Service Discovery according to feedback @ http://lists.w3.org/Archives/Public/public-device-apis/2012Aug/0017.html
Rich Tibbett <richt@opera.com>
parents: 216
diff changeset
   705
      </p>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   706
      <p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   707
        An IDL attribute is said to be <em>getting</em> when its value is being retrieved (e.g. by author script), and
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   708
        is said to be <em>setting</em> when a new value is assigned to it.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   709
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   710
      <p>
333
5e7aecddf47a Compile editor's draft
Rich Tibbett <richt@opera.com>
parents: 254
diff changeset
   711
        A <dfn id="dfn-valid-service-type">valid service type</dfn> is any of the following:
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   712
      </p>
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   713
      <ul>
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   714
        <li>a string that begins with <code>upnp:</code> or <code>zeroconf:</code> followed by one or more characters
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   715
        in the ranges U+0021, U+0023 to U+0027, U+002A to U+002B, U+002D to U+002E, U+0030 to U+0039, U+0041 to U+005A,
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   716
        U+005E to U+007E.
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   717
        </li>
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   718
        <li>a string that begins with <code>dial:</code> followed by an integer version.
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   719
        </li>
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
   720
      </ul>
333
5e7aecddf47a Compile editor's draft
Rich Tibbett <richt@opera.com>
parents: 254
diff changeset
   721
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   722
        A <a href="#dfn-valid-service-type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   723
           class="internalDFN">valid service type</a> provided in the <code>type</code> attribute of the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   724
           "#dom-navigator-getnetworkservices"><code>getNetworkServices()</code></a> method will be matched against the
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   725
           services currently contained in the <a href="#dfn-list-of-available-service-records"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   726
           class="internalDFN">list of available service records</a> according to the algorithms defined in this
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   727
           specification.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   728
      </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   729
      <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   730
        A <dfn id="dfn-user-agent-generated-callback-url">user-agent generated callback url</dfn> is a Local-network
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   731
        accessible <abbr title="Uniform Resource Locator">URL</abbr> endpoint that a <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   732
           class="internalDFN">user agent</a> generates and maintains for receiving <abbr title=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   733
           "Hypertext Transfer Protocol">HTTP</abbr> NOTIFY requests from UPnP Event sources. It is only required when
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   734
           the user agent implements UPnP Service Discovery as defined in this specification.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   735
      </p>
389
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   736
      <p>
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   737
        In this specification we use the following terms to describe the processes required for Local-networked
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   738
        Services management:
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   739
      </p>
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   740
      <ul>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   741
        <li>A <dfn id="dfn-new-service">new service</dfn> is a Local-networked Service that has not previously been
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   742
        discovered or registered in the <a href="#dfn-list-of-available-service-records"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   743
              class="internalDFN">list of available service records</a>.
389
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   744
        </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   745
        <li>An <dfn id="dfn-existing-service">existing service</dfn> is a Local-networked Service that has previously
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   746
        been discovered and is registered in the <a href="#dfn-list-of-available-service-records"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   747
              class="internalDFN">list of available service records</a>.
389
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   748
        </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   749
        <li>A <dfn id="dfn-current-service">current service</dfn> is a Local-networked Service, represented by a
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   750
        <a href="#networkservice"><code>NetworkService</code></a> object, that is currently being shared with a web
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   751
        page via a <a href="#networkservices"><code>NetworkServices</code></a> object registered in the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   752
        "#dfn-list-of-active-service-managers"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   753
              class="internalDFN">list of active service managers</a>.
389
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   754
        </li>
d5d955fd77bc Update NSD API Overview.html file
Rich Tibbett <richt@opera.com>
parents: 379
diff changeset
   755
      </ul>
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   756
    </section>
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   757
    <section id="security-and-privacy-considerations">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   758
      <h2 aria-level="1"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   759
          role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   760
          id="h2_security-and-privacy-considerations">
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   761
        <span class="secno">4.</span> Security and privacy considerations
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   762
      </h2>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   763
      <p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   764
        The <abbr title="Application Programming Interface">API</abbr> defined in this specification can be used to
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   765
        find and connect to devices and services within a user's current network. This discloses information related to
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   766
        a user's network: devices available on their network and the publicly-accessible services ("networked
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   767
        services") currently running and available on those devices. The distribution of this information could
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   768
        potentially compromise the user's privacy. A conforming implementation of this specification <em class=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   769
        "rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   770
           title="MUST">MUST</em> provide a mechanism that protects the user's privacy. This mechanism <em class=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   771
           "rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   772
           title="MUST">MUST</em> ensure that no networked service information is retrievable without the user's
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   773
           express permission.
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   774
      </p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   775
      <section id="privacy-considerations-for-api-implementations">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   776
        <h3 aria-level="2"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   777
            role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   778
            id="h3_privacy-considerations-for-api-implementations">
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   779
          <span class="secno">4.1</span> Privacy considerations for <abbr title=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   780
          "Application Programming Interface">API</abbr> implementations
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   781
        </h3>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   782
        <p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   783
          A <a href="#dfn-user-agent"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   784
             class="internalDFN">user agent</a> <em class="rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   785
             title="MUST NOT">MUST NOT</em> provide networked service information to web sites without the express
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   786
             permission of the user. A user agent <em class="rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   787
             title="MUST">MUST</em> acquire permission through a user interface, unless they have prearranged trust
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   788
             relationships with users, as described below. The user interface <em class="rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   789
             title="MUST">MUST</em> include the document base <abbr title="Uniform Resource Locator">URL</abbr>. Those
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   790
             permissions that are acquired through the user interface and that are preserved beyond the current
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   791
             browsing session (i.e. beyond the time when the browsing context is navigated to another <abbr title=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   792
             "Uniform Resource Locator">URL</abbr>) <em class="rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   793
             title="MUST">MUST</em> be revocable and a user agent <em class="rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   794
             title="MUST">MUST</em> respect revoked permissions.
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   795
        </p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   796
        <p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   797
          Obtaining the user's express permission to access one <abbr title=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   798
          "Application Programming Interface">API</abbr> method does not imply the user has granted permission for the
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   799
          same web site to access any other methods that may be provided by this <abbr title=
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   800
          "Application Programming Interface">API</abbr>, or to access the same method with a different set of
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   801
          arguments, as part of the same permission context. If a user has expressed permission for an implementation
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   802
          to, e.g. find a set of existing networked services, the implementation <em class="rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   803
             title="MUST">MUST</em> seek the user's express permission if and when any subsequent functions are called
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   804
             on this <abbr title="Application Programming Interface">API</abbr>.
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   805
        </p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   806
        <p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   807
          A user agent <em class="rfc2119"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   808
             title="MAY">MAY</em> have prearranged trust relationships that do not require such user interfaces. For
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   809
             example, while a web browser will present a user interface when a web site performs a networked service
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   810
             lookup, a different runtime may have a prearranged, delegated security relationship with the user and, as
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   811
             such, a suitable alternative security and privacy mechanism with which to authorise the retrieval of
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   812
             networked service information.
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   813
        </p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   814
      </section>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   815
      <section class="informative"
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   816
               id="additional-api-implementation-considerations">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   817
        <h3 aria-level="2"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   818
            role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   819
            id="h3_additional-api-implementation-considerations">
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   820
          <span class="secno">4.2</span> Additional <abbr title="Application Programming Interface">API</abbr>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   821
          implementation considerations
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   822
        </h3>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   823
        <p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   824
          <em>This section is non-normative.</em>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   825
        </p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   826
        <p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   827
          Further to the requirements listed in the previous section, implementors of the Network Service Discovery
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   828
          <abbr title="Application Programming Interface">API</abbr> are also advised to consider the following aspects
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   829
          that can negatively affect the privacy of their users: in certain cases, users can inadvertently grant
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   830
          permission to the user agent to disclose networked services to Web sites. In other cases, the content hosted
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   831
          at a certain <abbr title="Uniform Resource Locator">URL</abbr> changes in such a way that previously granted
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   832
          networked service permissions no longer apply as far as the user is concerned. Or the users might simply
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   833
          change their minds.
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   834
        </p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   835
        <p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   836
          Predicting or preventing these situations is inherently difficult. Mitigation and in-depth defensive measures
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   837
          are an implementation responsibility and not prescribed by this specification. However, in designing these
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   838
          measures, implementers are advised to enable user awareness of networked service sharing, and to provide easy
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   839
          access to interfaces that enable revocation of permissions that web applications have for accessing networked
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   840
          services via this <abbr title="Application Programming Interface">API</abbr>.
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   841
        </p>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   842
      </section>
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   843
    </section>
194
ad608906c611 Minor editorial to Networked Service Discovery
Rich Tibbett <richt@opera.com>
parents: 191
diff changeset
   844
    <section id="requesting-networked-services">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   845
      <h2 aria-level="1"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   846
          role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   847
          id="h2_requesting-networked-services">
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   848
        <span class="secno">5.</span> Requesting networked services
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   849
      </h2>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   850
      <pre class="widl">
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   851
[Supplemental, NoInterfaceObject]
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   852
interface <dfn id="navigatornetworkservice">NavigatorNetworkService</dfn> {
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   853
  <a class="externalDFN"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   854
     href="http://dom.spec.whatwg.org/#promise">Promise</a> <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   855
     "#dom-navigator-getnetworkservices">getNetworkServices</a>( in any type );
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   856
};
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   857
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   858
<a class="externalDFN"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   859
     href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   860
     "http://www.whatwg.org/specs/web-apps/current-work/complete/timers.html#navigator">Navigator</a> implements <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   861
     "#navigatornetworkservice">NavigatorNetworkService</a>;
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   862
</pre>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   863
      <section id="methods">
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   864
        <h3 aria-level="2"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   865
            role="heading"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   866
            id="h3_methods">
440
fcbaadc4fd54 Fix [DAP-ISSUE-135]: Add security and privacy considerations section [Network Service Discovery]
Rich Tibbett <richt@opera.com>
parents: 438
diff changeset
   867
          <span class="secno">5.1</span> Methods
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   868
        </h3>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   869
        <dl class="domintro">
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   870
          <dt>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   871
            <var title="">promise</var> = <var title="">window</var> . <code title="dom-navigator"><a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   872
            "http://www.whatwg.org/specs/web-apps/current-work/complete/timers.html#navigator">navigator</a></code> .
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   873
            <code title="dom-navigator-getNetworkServices"><a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   874
            "#dom-navigator-getnetworkservices">getNetworkServices</a></code> ( <var title="">type</var> )
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   875
          </dt>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   876
          <dd>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   877
            <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   878
              Immediately returns a new <a href="http://dom.spec.whatwg.org/#promise"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   879
                 class="externalDFN">Promise</a> object and then the user is prompted to select discovered network
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   880
                 services that have advertised support for the requested service type(s).
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   881
            </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   882
            <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   883
              The <var title="">type</var> argument contains one or more <a href="#dfn-valid-service-type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   884
                 class="internalDFN">valid service type</a> tokens that the web page would like to interact with.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   885
            </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   886
            <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   887
              If the user accepts, the <var title="">promise</var> object is <a class="externalDFN"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   888
                 href="http://dom.spec.whatwg.org/#concept-resolver-resolve">resolved</a>, with a <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   889
                 "#networkservices"><code>NetworkServices</code></a> object as its argument.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   890
            </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   891
            <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   892
              If the user declines, or an error occurs, the <var title="">promise</var> object is <a class=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   893
              "externalDFN"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   894
                 href="http://dom.spec.whatwg.org/#concept-resolver-reject">rejected</a>.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   895
            </p>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   896
          </dd>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   897
        </dl>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   898
        <div>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   899
          <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   900
            When the <dfn id="dom-navigator-getnetworkservices"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   901
               title="dom-navigator-getnetworkservices"><code>getNetworkServices(type)</code></dfn> method is called,
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   902
               the <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   903
               class="internalDFN">user agent</a> <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   904
               title="MUST">MUST</em> run the following steps:
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   905
          </p>
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   906
          <ol class="rule">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   907
            <li>Let <var>Network Service Promise</var> be a new <a href="http://dom.spec.whatwg.org/#promise"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   908
                  class="externalDFN"><code>Promise</code></a> object.
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   909
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   910
            <li>Let <var>Network Service Promise's Resolver</var> be the default <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   911
            "http://dom.spec.whatwg.org/#concept-resolver"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   912
                  class="externalDFN">resolver</a> of <var>Network Service Promise</var>.
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   913
            </li>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   914
            <li>Return <var>Network Service Promise</var>, and run the remaining steps asynchronously.
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   915
            </li>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   916
            <li>Let <var>requested control types</var> be initially set to an empty array.
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   917
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   918
            <li>If <var>type</var> is an array consisting of one or more <a href="#dfn-valid-service-type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   919
                  class="internalDFN">valid service type</a> tokens, then let <var>requested control types</var> by the
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   920
                  value of <var>type</var>, removing any non-<a href="#dfn-valid-service-type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   921
                  class="internalDFN">valid service type</a> tokens from the resulting array.
333
5e7aecddf47a Compile editor's draft
Rich Tibbett <richt@opera.com>
parents: 254
diff changeset
   922
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   923
            <li>If <var>type</var> is a string consisting of one <a href="#dfn-valid-service-type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   924
                  class="internalDFN">valid service type</a> token, then let <var>requested control types</var> be an
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   925
                  array containing one item with a value of <var>type</var>.
402
a3626e492d27 Add WD (29th March 2013) for Network Service Discovery API
Rich Tibbett <richt@opera.com>
parents: 392
diff changeset
   926
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   927
            <li>If <var>requested control types</var> is an array that contains at least one or more <a title=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   928
            "valid service type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   929
                  href="#dfn-valid-service-type"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   930
                  class="internalDFN">valid service type</a> tokens then continue to the step labeled <em>process</em>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   931
                  below. Otherwise, reject <var>Network Service Promise</var> by running the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   932
                  "http://dom.spec.whatwg.org/#concept-resolver-reject"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   933
                  class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   934
                  Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   935
                  class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the string
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   936
                  value "UnknownTypePrefixError" (<a href=
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   937
                  "#dom-domerror-extensions-unknown_type_prefix"><code>UNKNOWN_TYPE_PREFIX_ERR</code></a>) and whose
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   938
                  <code>message</code> attribute has a helpful implementation-dependent message that explains this
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   939
                  error, abort any remaining steps and return.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   940
            </li>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   941
            <li>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   942
              <em>Process</em>: Let <var>services found</var> be an empty array.
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   943
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   944
            <li>For each <var>available service</var> in the <a href="#dfn-list-of-available-service-records"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   945
                  class="internalDFN">list of available service records</a> run the following steps:
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   946
              <ol class="rule">
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   947
                <li>For each <var>requested control type</var> in <var>requested control types</var>: If <var>available
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   948
                service</var>'s <code>type</code> attribute equals the <var>requested control type</var> then let <var>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   949
                  matched service</var> equal the value of <var>available service</var> and continue at the step
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   950
                  labeled <var>attach</var> below.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   951
                </li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   952
                <li>Continue at the next <var>available service</var>.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   953
                </li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   954
                <li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   955
                  <em>Attach</em>: If <var>matched service</var> is not empty then run the following steps:
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   956
                  <ol class="rule">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   957
                    <li>Let <var>new service object</var> be a new <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   958
                    "#networkservice"><code>NetworkService</code></a> object, mapping the parameters of <var>matched
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   959
                    service</var> to this new object where possible.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   960
                    </li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   961
                    <li>Append <var>new service object</var> to the <var>services found</var> array.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   962
                    </li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   963
                  </ol>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   964
                </li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   965
              </ol>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   966
            </li>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   967
            <li>Optionally, e.g. based on a previously-established user preference, for security reasons, or due to
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   968
            platform limitations, the <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   969
                  class="internalDFN">user agent</a> <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   970
                  title="MAY">MAY</em> reject <var>Network Service Promise</var> by running the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   971
                  "http://dom.spec.whatwg.org/#concept-resolver-reject"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   972
                  class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   973
                  Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   974
                  class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the string
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   975
                  value "PermissionDeniedError" (<a href=
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   976
                  "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) and whose
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   977
                  <code>message</code> attribute has a helpful implementation-dependent message that explains this
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
   978
                  error, abort any remaining steps and return.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   979
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   980
            <li>The user agent <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   981
                  title="MUST NOT">MUST NOT</em> provide the entry script's origin with a <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   982
                  "#networkservices"><code>NetworkServices</code></a> object without prior permission given by the
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   983
                  user.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   984
              <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   985
                If <var>services found</var> is not an empty array then the <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   986
                   class="internalDFN">user agent</a> <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   987
                   title="MAY">MAY</em> choose to prompt the user in a user-agent-specific manner for permission to
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   988
                   provide the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   989
                   "http://www.whatwg.org/specs/web-apps/current-work/complete/browsers.html#entry-script"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   990
                   class="externalDFN">entry script</a>'s <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   991
                   "http://www.whatwg.org/specs/web-apps/current-work/complete/origin-0.html#origin"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   992
                   class="externalDFN">origin</a> with a <a href="#networkservices"><code>NetworkServices</code></a>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   993
                   object representing the <a href="#dfn-user-authorized"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   994
                   class="internalDFN">user-authorized</a> subset of <var>services found</var>.
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
   995
              </p>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
   996
              <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   997
                Alternatively, the user agent <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   998
                   title="MAY">MAY</em> wish to skip this user opt-in step and choose to fulfill <var>Network Service
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
   999
                   Promise</var> immediately based on a previously-established user preference, for security reasons,
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1000
                   or due to platform limitations. In such an implementation, if <var>Network Service Promise</var> is
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1001
                   to be fulfilled as a result of a previously-established user preference then the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1002
                   "#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1003
                   class="internalDFN">user agent</a> <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1004
                   title="MUST">MUST</em> continue at the next step of this algorithm.
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1005
              </p>
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1006
              <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1007
                If permission has been granted by the user to access one or more networked services then the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1008
                "#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1009
                   class="internalDFN">user agent</a> <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1010
                   title="SHOULD">SHOULD</em> include an "ongoing local-network communication" indicator.
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1011
              </p>
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1012
              <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1013
                If permission has been denied by the user, <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1014
                   class="internalDFN">user agent</a> or platform, then the <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1015
                   class="internalDFN">user agent</a> <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1016
                   title="MUST">MUST</em> reject <var>Network Service Promise</var> by running the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1017
                   "http://dom.spec.whatwg.org/#concept-resolver-reject"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1018
                   class="externalDFN">resolver reject algorithm</a> against the <var>Network Service Promise's
447
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
  1019
                   Resolver</var>, passing in a newly constructed <a href="http://dom.spec.whatwg.org/#domerror"
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
  1020
                   class="externalDFN"><code>DOMError</code></a> object whose <code>name</code> attribute has the
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
  1021
                   string value "PermissionDeniedError" (<a href=
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
  1022
                   "#dom-domerror-extensions-permission_denied"><code>PERMISSION_DENIED_ERR</code></a>) and whose
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
  1023
                   <code>message</code> attribute has a helpful implementation-dependent message that explains this
5e36d90b8960 Replace numeric error codes with string-based error types and fold the NavigatorNetworkServiceError interface in to DOMError (therefore, removing NavigatorNetworkServiceError from spec)
Rich Tibbett <richt@opera.com>
parents: 441
diff changeset
  1024
                   error, abort any remaining steps and return.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1025
              </p>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1026
              <p>
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1027
                If the user never responds or no previously-established user preference has been met, this algorithm
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1028
                stalls on this step.
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1029
              </p>
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1030
            </li>
254
f29ec967fb3b Editorial updates to NSD spec
Rich Tibbett <richt@opera.com>
parents: 250
diff changeset
  1031
            <li>Let <var>services</var> be an empty array.
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1032
            </li>
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1033
            <li>If <var>services found</var> is not an empty array then set <var>services</var> to be an array of one
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1034
            or more <a href="#networkservice"><code>NetworkService</code></a> objects for which the user granted
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1035
            permission above - known as the current objects <dfn id="dfn-user-authorized">user-authorized</dfn>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1036
            services.
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1037
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1038
            <li>Remove all previously whitelisted urls from the <a href="#dfn-entry-script-origin-s-url-whitelist"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1039
                  class="internalDFN">entry script origin's <abbr title="Uniform Resource Locator">URL</abbr>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1040
                  whitelist</a> granted in the current <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1041
                  "http://www.whatwg.org/specs/web-apps/current-work/complete/browsers.html#entry-script"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1042
                  class="externalDFN">entry script</a>'s <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1043
                  "http://www.whatwg.org/specs/web-apps/current-work/complete/origin-0.html#origin"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1044
                  class="externalDFN">origin</a>.
254
f29ec967fb3b Editorial updates to NSD spec
Rich Tibbett <richt@opera.com>
parents: 250
diff changeset
  1045
            </li>
f29ec967fb3b Editorial updates to NSD spec
Rich Tibbett <richt@opera.com>
parents: 250
diff changeset
  1046
            <li>For each Object <var>service</var> in <var>services</var>, if any, run the following sub-steps:
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1047
              <ol class="rule">
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1048
                <li>Add the <var>service</var>'s <code>url</code> parameter to the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1049
                "#dfn-entry-script-origin-s-url-whitelist"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1050
                      class="internalDFN">entry script origin's <abbr title="Uniform Resource Locator">URL</abbr>
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1051
                      whitelist</a>.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1052
                </li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1053
                <li>If <var>service</var>'s <code>type</code> parameter begins with the DOMString "<code>upnp:</code>"
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1054
                and the <var>service</var>'s <code>eventsUrl</code> parameter is not empty then <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1055
                "#dfn-setup-a-upnp-events-subscription"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1056
                      class="internalDFN">setup a UPnP Events Subscription</a> for <var>service</var>.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1057
                </li>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1058
              </ol>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1059
            </li>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1060
            <li>Let <var>services manager</var> be a new <a href="#networkservices"><code>NetworkServices</code></a>
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1061
            object.
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1062
            </li>
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1063
            <li>Store <var>requested control types</var> against <var>services manager</var> as an internal variable.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1064
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1065
            <li>Set <var>services manager</var>'s <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1066
            "#dom-networkservices-servicesavailable"><code>servicesAvailable</code></a> attribute to the number of
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1067
            items currently found in the <a href="#dfn-list-of-available-service-records"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1068
                  class="internalDFN">list of available service records</a> whose <code>type</code> property matches
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1069
                  any of the tokens requested in <var>requested control types</var>.
379
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1070
            </li>
7a9a351e1577 Update compiled editor's draft of NSD API with latest changes
Rich Tibbett <richt@opera.com>
parents: 333
diff changeset
  1071
            <li>Add <var>services</var>, if any, to the <var>services manager</var> object as its collection of
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1072
              <a href="#dfn-indexed-properties-1"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1073
                  class="internalDFN">indexed properties</a>. If <var>services</var> is an empty array then the
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1074
                  <var>services manager</var> does not have any <var>indexed properties</var>.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1075
            </li>
250
8b912f2bb9c7 Updates to Service Discovery & Messaging according to feedback @ http://lists.w3.org/Archives/Public/public-device-apis/2012Oct/0005.html
Rich Tibbett <richt@opera.com>
parents: 247
diff changeset
  1076
            <li>Set <var>services manager</var>'s <a href="#dom-networkservices-length"><code>length</code></a>
8b912f2bb9c7 Updates to Service Discovery & Messaging according to feedback @ http://lists.w3.org/Archives/Public/public-device-apis/2012Oct/0005.html
Rich Tibbett <richt@opera.com>
parents: 247
diff changeset
  1077
            attribute to the number of items in <var>services</var>.
8b912f2bb9c7 Updates to Service Discovery & Messaging according to feedback @ http://lists.w3.org/Archives/Public/public-device-apis/2012Oct/0005.html
Rich Tibbett <richt@opera.com>
parents: 247
diff changeset
  1078
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1079
            <li>Add <var>services manager</var> to the <a href="#dfn-list-of-active-service-managers"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1080
                  class="internalDFN">list of active service managers</a>.
250
8b912f2bb9c7 Updates to Service Discovery & Messaging according to feedback @ http://lists.w3.org/Archives/Public/public-device-apis/2012Oct/0005.html
Rich Tibbett <richt@opera.com>
parents: 247
diff changeset
  1081
            </li>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1082
            <li>The <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1083
                  class="internalDFN">user agent</a> <em class="rfc2119"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1084
                  title="MUST">MUST</em> fulfill <var>Network Service Promise</var> by running the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1085
                  "http://dom.spec.whatwg.org/#concept-resolver-fulfill"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1086
                  class="externalDFN">resolver fulfill algorithm</a> against the <var>Network Service Promise's
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1087
                  Resolver</var>, passing in <var>services manager</var> as its argument.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1088
            </li>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1089
          </ol>
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1090
          <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1091
            The <a href="http://www.whatwg.org/specs/web-apps/current-work/complete/webappapis.html#task-source"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1092
               class="externalDFN">task source</a> for these <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1093
               "http://www.whatwg.org/specs/web-apps/current-work/complete/webappapis.html#concept-task"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1094
               class="externalDFN">tasks</a> is the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1095
               "http://www.whatwg.org/specs/web-apps/current-work/complete/webappapis.html#user-interaction-task-source"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1096
               class="externalDFN">user interaction task source</a>.
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1097
          </p>
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1098
          <p>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1099
            When a <a href="#networkservice"><code>NetworkService</code></a> object is provided to a Web page, the
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1100
            <a href="#dfn-user-agent"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1101
               class="internalDFN">user agent</a> <em class="rfc2119"
441
b4b2569b4e9b Fix [DAP-ISSUE-136]: Issues related to garbage collection
Rich Tibbett <richt@opera.com>
parents: 440
diff changeset
  1102
               title="MUST">MUST</em> add its <a href="#dom-networkservice-url"><code>url</code></a> to the <dfn id=
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1103
               "dfn-entry-script-origin-s-url-whitelist">entry script origin's <abbr title=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1104
               "Uniform Resource Locator">URL</abbr> whitelist</dfn>. This list enables the Web page to override and
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1105
               initiate cross-site resource requests towards these URLs, and any sub-resources of these URLs, within
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1106
               the current <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1107
               "http://www.whatwg.org/specs/web-apps/current-work/complete/browsers.html#entry-script"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1108
               class="externalDFN">entry script</a>'s <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1109
               "http://www.whatwg.org/specs/web-apps/current-work/complete/origin-0.html#origin"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1110
               class="externalDFN">origin</a> via various existing mechanisms (e.g. Web Sockets, Server-Sent Events,
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1111
               Web Messaging, XMLHttpRequest).
180
ee3a89da06e1 First draft of Networked Service Discovery and Messaging
Rich Tibbett <richt@opera.com>
parents:
diff changeset
  1112
          </p>
239
7e34654692fc HTML5 Tidy on Network Service Discovery spec markup
Rich Tibbett <richt@opera.com>
parents: 238
diff changeset
  1113
          <p>
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1114
            If the user navigates away from the <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1115
            "http://www.whatwg.org/specs/web-apps/current-work/complete/browsers.html#entry-script"
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1116
               class="externalDFN">entry script</a>'s <a href=
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <richt@opera.com>
parents: 402
diff changeset
  1117
               "http://www.whatwg.org/specs/web-apps/current-work/complete/origin-0.html#origin"
441
b4b2569b4e9b Fix [DAP-ISSUE-136]: Issues related to garbage collection
Rich Tibbett <richt@opera.com>
parents: 440
diff changeset
  1118
               class="externalDFN">origin</a> or permission to access a given networked service is revoked at any time
b4b2569b4e9b Fix [DAP-ISSUE-136]: Issues related to garbage collection
Rich Tibbett <richt@opera.com>
parents: 440
diff changeset
  1119
               by the platform or user then the <a href="#dfn-user-agent"
437
d25229263a68 Change getNetworkServices API + associated algorithms to use DOM Promises
Rich Tibbett <