// Code generated by "./generator ./system/org.lingmo.greeter1"; DO NOT EDIT.

// SPDX-FileCopyrightText: 2018 - 2023 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: GPL-3.0-or-later
package greeter1

import (
	"unsafe"

	"github.com/godbus/dbus/v5"
	"github.com/LingmoOS/golang-github-lingmo-go-lib/dbusutil/proxy"
)

type Greeter interface {
	greeter // interface org.lingmo.Greeter1
	proxy.Object
}

type objectGreeter struct {
	interfaceGreeter // interface org.lingmo.Greeter1
	proxy.ImplObject
}

func NewGreeter(conn *dbus.Conn) Greeter {
	obj := new(objectGreeter)
	obj.ImplObject.Init_(conn, "org.lingmo.Greeter1", "/org/lingmo/Greeter1")
	return obj
}

type greeter interface {
	GoUpdateGreeterQtTheme(flags dbus.Flags, ch chan *dbus.Call, fd dbus.UnixFD) *dbus.Call
	UpdateGreeterQtTheme(flags dbus.Flags, fd dbus.UnixFD) error
}

type interfaceGreeter struct{}

func (v *interfaceGreeter) GetObject_() *proxy.ImplObject {
	return (*proxy.ImplObject)(unsafe.Pointer(v))
}

func (*interfaceGreeter) GetInterfaceName_() string {
	return "org.lingmo.Greeter1"
}

// method UpdateGreeterQtTheme

func (v *interfaceGreeter) GoUpdateGreeterQtTheme(flags dbus.Flags, ch chan *dbus.Call, fd dbus.UnixFD) *dbus.Call {
	return v.GetObject_().Go_(v.GetInterfaceName_()+".UpdateGreeterQtTheme", flags, ch, fd)
}

func (v *interfaceGreeter) UpdateGreeterQtTheme(flags dbus.Flags, fd dbus.UnixFD) error {
	return (<-v.GoUpdateGreeterQtTheme(flags, make(chan *dbus.Call, 1), fd).Done).Err
}
