use std::collections::HashMap;
use zbus::{
proxy,
zvariant::{OwnedObjectPath, OwnedValue},
};
pub mod connection;
#[proxy(
default_service = "org.freedesktop.NetworkManager",
interface = "org.freedesktop.NetworkManager.Settings",
default_path = "/org/freedesktop/NetworkManager/Settings"
)]
pub(crate) trait Settings {
fn list_connections(&self) -> zbus::Result<Vec<OwnedObjectPath>>;
fn get_connection_by_uuid(&self, uuid: &str) -> zbus::Result<OwnedObjectPath>;
fn add_connection(
&self,
connection: HashMap<String, HashMap<String, OwnedValue>>,
) -> zbus::Result<OwnedObjectPath>;
fn add_connection_unsaved(
&self,
connection: HashMap<String, HashMap<String, OwnedValue>>,
) -> zbus::Result<OwnedObjectPath>;
fn add_connection2(
&self,
settings: HashMap<String, HashMap<String, OwnedValue>>,
flags: u32,
args: HashMap<String, OwnedValue>,
) -> zbus::Result<(OwnedObjectPath, HashMap<String, OwnedValue>)>;
fn load_connections(&self, filenames: Vec<String>) -> zbus::Result<(bool, Vec<String>)>;
fn reload_connections(&self) -> zbus::Result<bool>;
fn save_hostname(&self, hostname: &str) -> zbus::Result<()>;
#[zbus(property)]
fn connections(&self) -> zbus::Result<Vec<OwnedObjectPath>>;
#[zbus(property)]
fn hostname(&self) -> zbus::Result<String>;
#[zbus(property)]
fn can_modify(&self) -> zbus::Result<bool>;
#[zbus(property)]
fn version_id(&self) -> zbus::Result<u64>;
#[zbus(signal)]
fn new_connection(&self, connection: OwnedObjectPath) -> zbus::Result<()>;
#[zbus(signal)]
fn connection_removed(&self, connection: OwnedObjectPath) -> zbus::Result<()>;
}