/
auto.go
76 lines (58 loc) · 2.16 KB
/
auto.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
// Code generated by "./generator ./session/com.deepin.api.pinyin"; DO NOT EDIT.
// SPDX-FileCopyrightText: 2018 - 2023 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: GPL-3.0-or-later
package pinyin
import "github.com/godbus/dbus/v5"
import "github.com/linuxdeepin/go-lib/dbusutil/proxy"
import "unsafe"
type Pinyin interface {
pinyin // interface com.deepin.api.Pinyin
proxy.Object
}
type objectPinyin struct {
interfacePinyin // interface com.deepin.api.Pinyin
proxy.ImplObject
}
func NewPinyin(conn *dbus.Conn) Pinyin {
obj := new(objectPinyin)
obj.ImplObject.Init_(conn, "com.deepin.api.Pinyin", "/com/deepin/api/Pinyin")
return obj
}
type pinyin interface {
GoQuery(flags dbus.Flags, ch chan *dbus.Call, hans string) *dbus.Call
Query(flags dbus.Flags, hans string) ([]string, error)
GoQueryList(flags dbus.Flags, ch chan *dbus.Call, hansList []string) *dbus.Call
QueryList(flags dbus.Flags, hansList []string) (string, error)
}
type interfacePinyin struct{}
func (v *interfacePinyin) GetObject_() *proxy.ImplObject {
return (*proxy.ImplObject)(unsafe.Pointer(v))
}
func (*interfacePinyin) GetInterfaceName_() string {
return "com.deepin.api.Pinyin"
}
// method Query
func (v *interfacePinyin) GoQuery(flags dbus.Flags, ch chan *dbus.Call, hans string) *dbus.Call {
return v.GetObject_().Go_(v.GetInterfaceName_()+".Query", flags, ch, hans)
}
func (*interfacePinyin) StoreQuery(call *dbus.Call) (pinyin []string, err error) {
err = call.Store(&pinyin)
return
}
func (v *interfacePinyin) Query(flags dbus.Flags, hans string) ([]string, error) {
return v.StoreQuery(
<-v.GoQuery(flags, make(chan *dbus.Call, 1), hans).Done)
}
// method QueryList
func (v *interfacePinyin) GoQueryList(flags dbus.Flags, ch chan *dbus.Call, hansList []string) *dbus.Call {
return v.GetObject_().Go_(v.GetInterfaceName_()+".QueryList", flags, ch, hansList)
}
func (*interfacePinyin) StoreQueryList(call *dbus.Call) (json string, err error) {
err = call.Store(&json)
return
}
func (v *interfacePinyin) QueryList(flags dbus.Flags, hansList []string) (string, error) {
return v.StoreQueryList(
<-v.GoQueryList(flags, make(chan *dbus.Call, 1), hansList).Done)
}