Skip to content

Commit c29a043

Browse files
committed
doc: Updating documentation formatting
1 parent 189f762 commit c29a043

File tree

1 file changed

+20
-20
lines changed

1 file changed

+20
-20
lines changed

doc.go

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
1-
/*
2-
Package xmlrpc includes everything that is required to perform XML-RPC requests by utilizing familiar rpc.Client interface.
1+
//
2+
// Package xmlrpc includes everything that is required to perform XML-RPC requests by utilizing familiar rpc.Client interface.
3+
//
4+
// The simplest use-case is creating a client towards an endpoint and making calls:
5+
//
6+
//
7+
// c, _ := NewClient("https://bugzilla.mozilla.org/xmlrpc.cgi")
8+
//
9+
// resp := &struct {
10+
// BugzillaVersion struct {
11+
// Version string
12+
// }
13+
// }{}
14+
//
15+
// err = c.Call("Bugzilla.version", nil, resp)
16+
// fmt.Printf("Version: %s\n", resp.BugzillaVersion.Version)
17+
//
18+
//
19+
// Additional customizations, such as setting custom headers, changing User-Agent or modifying HTTP Client used to make calls,
20+
// pass corresponding Options to NewClient function.
321

4-
The simplest use-case is creating a client towards an endpoint and making calls:
5-
6-
7-
c, _ := NewClient("https://bugzilla.mozilla.org/xmlrpc.cgi")
8-
9-
resp := &struct {
10-
BugzillaVersion struct {
11-
Version string
12-
}
13-
}{}
14-
15-
err = c.Call("Bugzilla.version", nil, resp)
16-
fmt.Printf("Version: %s\n", resp.BugzillaVersion.Version)
17-
18-
19-
Additional customizations, such as setting custom headers, changing User-Agent or modifying HTTP Client used to make calls,
20-
pass corresponding Options to NewClient function.
21-
*/
2222
package xmlrpc

0 commit comments

Comments
 (0)