Add documentation links to service docs.

This commit is contained in:
John Beisley 2022-06-13 18:06:03 +01:00
parent befb173f08
commit 23b5557105
5 changed files with 14 additions and 0 deletions

View File

@ -211,6 +211,9 @@ type ServiceManifest struct {
ServiceType string `toml:"type"`
// Path within the DCP spec ZIP file e.g. "xml data files/service/Foo1.xml".
Path string `toml:"path"`
// DocumentURL is the URL to the documentation for the service.
DocumentURL string `toml:"document_url"`
}
type tmplArgs struct {

View File

@ -1,4 +1,6 @@
// Package lanhostcfgmgmt1 provides types for the "urn:schemas-upnp-org:service:LANHostConfigManagement:1" service.
//
// Documented at https://openconnectivity.org/wp-content/uploads/2015/11/UPnP-gw-LANHostConfigManagement-v1-Service.pdf.
package lanhostcfgmgmt1
import (

View File

@ -1,4 +1,6 @@
// Package wanpppconn1 provides types for the "urn:schemas-upnp-org:service:WANPPPConnection:1" service.
//
// Documented at https://openconnectivity.org/wp-content/uploads/2015/11/UPnP_IGD_WANPPPConnection-1.0.pdf.
package wanpppconn1
import (

View File

@ -1,6 +1,10 @@
{{define "service"}}
{{- $Imps := .Imps -}}
// Package {{.Manifest.Package}} provides types for the {{quote .Manifest.ServiceType}} service.
{{- with .Manifest.DocumentURL}}
//
// Documented at {{.}}.
{{- end}}
package {{.Manifest.Package}}
import (

View File

@ -1,11 +1,14 @@
[[dcp]]
spec_zip_path = "standardizeddcps/Internet Gateway_2/UPnP-gw-IGD-TestFiles-20101210.zip"
output_dir = "inetgw2"
# https://openconnectivity.org/wp-content/uploads/2015/11/UPnP-gw-InternetGatewayDevice-v2-Device-20100910.pdf
[[dcp.service]]
package = "lanhostcfgmgmt1"
type = "urn:schemas-upnp-org:service:LANHostConfigManagement:1"
path = "xml data files/service/LANHostConfigManagement1.xml"
document_url = "https://openconnectivity.org/wp-content/uploads/2015/11/UPnP-gw-LANHostConfigManagement-v1-Service.pdf"
[[dcp.service]]
package = "wanpppconn1"
type = "urn:schemas-upnp-org:service:WANPPPConnection:1"
path = "xml data files/service/WANPPPConnection1.xml"
document_url = "https://openconnectivity.org/wp-content/uploads/2015/11/UPnP_IGD_WANPPPConnection-1.0.pdf"