feat: zbus 4.2.1 update
This commit is contained in:
parent
f05789c4ce
commit
d2d14d6610
3 changed files with 22 additions and 22 deletions
|
|
@ -19,4 +19,4 @@ serde = { version = "1.0", features = ["derive"] }
|
||||||
thiserror = "1.0"
|
thiserror = "1.0"
|
||||||
time = { version = "0.3", features = ["parsing"] }
|
time = { version = "0.3", features = ["parsing"] }
|
||||||
zbus = { version = "4.2.1" }
|
zbus = { version = "4.2.1" }
|
||||||
zvariant = { version = "4.1.0"}
|
zvariant = { version = "4.1.0" }
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ categories = ["os::linux-apis"]
|
||||||
keywords = ["dbus", "hostname", "hostname1", "zbus", "freedesktop"]
|
keywords = ["dbus", "hostname", "hostname1", "zbus", "freedesktop"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
zbus = "3.0.0"
|
zbus = "4.2.1"
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
pico-args = "0.5.0"
|
pico-args = "0.5.0"
|
||||||
|
|
|
||||||
|
|
@ -19,9 +19,9 @@
|
||||||
//!
|
//!
|
||||||
//! …consequently `zbus-xmlgen` did not generate code for the above interfaces.
|
//! …consequently `zbus-xmlgen` did not generate code for the above interfaces.
|
||||||
|
|
||||||
use zbus::dbus_proxy;
|
use zbus::dbus;
|
||||||
|
|
||||||
#[dbus_proxy(
|
#[dbus(
|
||||||
interface = "org.freedesktop.hostname1",
|
interface = "org.freedesktop.hostname1",
|
||||||
default_service = "org.freedesktop.hostname1",
|
default_service = "org.freedesktop.hostname1",
|
||||||
default_path = "/org/freedesktop/hostname1"
|
default_path = "/org/freedesktop/hostname1"
|
||||||
|
|
@ -31,7 +31,7 @@ trait Hostname1 {
|
||||||
fn describe(&self) -> zbus::Result<String>;
|
fn describe(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// GetProductUUID method
|
/// GetProductUUID method
|
||||||
#[dbus_proxy(name = "GetProductUUID")]
|
#[zbus(name = "GetProductUUID")]
|
||||||
fn get_product_uuid(&self, interactive: bool) -> zbus::Result<Vec<u8>>;
|
fn get_product_uuid(&self, interactive: bool) -> zbus::Result<Vec<u8>>;
|
||||||
|
|
||||||
/// SetChassis method
|
/// SetChassis method
|
||||||
|
|
@ -56,70 +56,70 @@ trait Hostname1 {
|
||||||
fn set_static_hostname(&self, hostname: &str, interactive: bool) -> zbus::Result<()>;
|
fn set_static_hostname(&self, hostname: &str, interactive: bool) -> zbus::Result<()>;
|
||||||
|
|
||||||
/// Chassis property
|
/// Chassis property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn chassis(&self) -> zbus::Result<String>;
|
fn chassis(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// DefaultHostname property
|
/// DefaultHostname property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn default_hostname(&self) -> zbus::Result<String>;
|
fn default_hostname(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// Deployment property
|
/// Deployment property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn deployment(&self) -> zbus::Result<String>;
|
fn deployment(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// HardwareModel property
|
/// HardwareModel property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn hardware_model(&self) -> zbus::Result<String>;
|
fn hardware_model(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// HardwareVendor property
|
/// HardwareVendor property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn hardware_vendor(&self) -> zbus::Result<String>;
|
fn hardware_vendor(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// HomeURL property
|
/// HomeURL property
|
||||||
#[dbus_proxy(property, name = "HomeURL")]
|
#[zbus(property, name = "HomeURL")]
|
||||||
fn home_url(&self) -> zbus::Result<String>;
|
fn home_url(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// Hostname property
|
/// Hostname property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn hostname(&self) -> zbus::Result<String>;
|
fn hostname(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// HostnameSource property
|
/// HostnameSource property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn hostname_source(&self) -> zbus::Result<String>;
|
fn hostname_source(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// IconName property
|
/// IconName property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn icon_name(&self) -> zbus::Result<String>;
|
fn icon_name(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// KernelName property
|
/// KernelName property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn kernel_name(&self) -> zbus::Result<String>;
|
fn kernel_name(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// KernelRelease property
|
/// KernelRelease property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn kernel_release(&self) -> zbus::Result<String>;
|
fn kernel_release(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// KernelVersion property
|
/// KernelVersion property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn kernel_version(&self) -> zbus::Result<String>;
|
fn kernel_version(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// Location property
|
/// Location property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn location(&self) -> zbus::Result<String>;
|
fn location(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// OperatingSystemCPEName property
|
/// OperatingSystemCPEName property
|
||||||
#[dbus_proxy(property, name = "OperatingSystemCPEName")]
|
#[zbus(property, name = "OperatingSystemCPEName")]
|
||||||
fn operating_system_cpename(&self) -> zbus::Result<String>;
|
fn operating_system_cpename(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// OperatingSystemPrettyName property
|
/// OperatingSystemPrettyName property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn operating_system_pretty_name(&self) -> zbus::Result<String>;
|
fn operating_system_pretty_name(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// PrettyHostname property
|
/// PrettyHostname property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn pretty_hostname(&self) -> zbus::Result<String>;
|
fn pretty_hostname(&self) -> zbus::Result<String>;
|
||||||
|
|
||||||
/// StaticHostname property
|
/// StaticHostname property
|
||||||
#[dbus_proxy(property)]
|
#[zbus(property)]
|
||||||
fn static_hostname(&self) -> zbus::Result<String>;
|
fn static_hostname(&self) -> zbus::Result<String>;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue