sdbusplus: use shorter type aliases

The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines.  Possible replacements are for:
  * bus_t
  * exception_t
  * manager_t
  * match_t
  * message_t
  * object_t
  * slot_t

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ief1b330c4f623ecc1be771f36083780a12260834
diff --git a/src/dhcp_configuration.hpp b/src/dhcp_configuration.hpp
index 272959a..f35701b 100644
--- a/src/dhcp_configuration.hpp
+++ b/src/dhcp_configuration.hpp
@@ -20,7 +20,7 @@
 using ConfigIntf =
     sdbusplus::xyz::openbmc_project::Network::server::DHCPConfiguration;
 
-using Iface = sdbusplus::server::object::object<ConfigIntf>;
+using Iface = sdbusplus::server::object_t<ConfigIntf>;
 
 /** @class Configuration
  *  @brief DHCP configuration.
@@ -42,7 +42,7 @@
      *  @param[in] objPath - Path to attach at.
      *  @param[in] parent - Parent object.
      */
-    Configuration(sdbusplus::bus::bus& bus, const std::string& objPath,
+    Configuration(sdbusplus::bus_t& bus, const std::string& objPath,
                   Manager& parent) :
         Iface(bus, objPath.c_str(), Iface::action::defer_emit),
         bus(bus), manager(parent)
@@ -101,7 +101,7 @@
 
   private:
     /** @brief sdbusplus DBus bus connection. */
-    sdbusplus::bus::bus& bus;
+    sdbusplus::bus_t& bus;
 
     /** @brief Network Manager object. */
     phosphor::network::Manager& manager;
diff --git a/src/ethernet_interface.cpp b/src/ethernet_interface.cpp
index 312bd9d..77e5df1 100644
--- a/src/ethernet_interface.cpp
+++ b/src/ethernet_interface.cpp
@@ -59,7 +59,7 @@
     return fd;
 }
 
-EthernetInterface::EthernetInterface(sdbusplus::bus::bus& bus,
+EthernetInterface::EthernetInterface(sdbusplus::bus_t& bus,
                                      const std::string& objPath,
                                      DHCPConf dhcpEnabled, Manager& parent,
                                      bool emitSignal,
@@ -658,13 +658,13 @@
 
     // Build a matcher before making the property call to ensure we
     // can eventually get the value.
-    sdbusplus::bus::match::match match(
+    sdbusplus::bus::match_t match(
         bus,
         fmt::format("type='signal',sender='{}',path='{}',interface='{}',member="
                     "'PropertiesChanged',arg0='{}',",
                     svc, path, PROPERTY_INTERFACE, intf)
             .c_str(),
-        [&](sdbusplus::message::message& m) {
+        [&](sdbusplus::message_t& m) {
             std::string intf;
             std::unordered_map<std::string, std::variant<std::string>> values;
             try
@@ -847,7 +847,7 @@
     {
         reply.read(name);
     }
-    catch (const sdbusplus::exception::exception& e)
+    catch (const sdbusplus::exception_t& e)
     {
         log<level::ERR>("Failed to get DNS information from Systemd-Resolved");
     }
diff --git a/src/ethernet_interface.hpp b/src/ethernet_interface.hpp
index 8928455..592d690 100644
--- a/src/ethernet_interface.hpp
+++ b/src/ethernet_interface.hpp
@@ -18,7 +18,7 @@
 namespace network
 {
 
-using Ifaces = sdbusplus::server::object::object<
+using Ifaces = sdbusplus::server::object_t<
     sdbusplus::xyz::openbmc_project::Network::server::EthernetInterface,
     sdbusplus::xyz::openbmc_project::Network::server::MACAddress,
     sdbusplus::xyz::openbmc_project::Network::IP::server::Create,
@@ -86,7 +86,7 @@
      *                          send.
      *  @param[in] enabled - Override the lookup of nicEnabled
      */
-    EthernetInterface(sdbusplus::bus::bus& bus, const std::string& objPath,
+    EthernetInterface(sdbusplus::bus_t& bus, const std::string& objPath,
                       DHCPConf dhcpEnabled, Manager& parent,
                       bool emitSignal = true,
                       std::optional<bool> enabled = std::nullopt);
@@ -327,7 +327,7 @@
     ServerList getstaticNameServerFromConf();
 
     /** @brief Persistent sdbusplus DBus bus connection. */
-    sdbusplus::bus::bus& bus;
+    sdbusplus::bus_t& bus;
 
     /** @brief Network Manager object. */
     Manager& manager;
diff --git a/src/ibm/hypervisor-network-mgr-src/hyp_network_manager.hpp b/src/ibm/hypervisor-network-mgr-src/hyp_network_manager.hpp
index 5616c66..ca21ece 100644
--- a/src/ibm/hypervisor-network-mgr-src/hyp_network_manager.hpp
+++ b/src/ibm/hypervisor-network-mgr-src/hyp_network_manager.hpp
@@ -68,7 +68,7 @@
      *  @param[in] event - event.
      *  @param[in] path - Path to attach at.
      */
-    HypNetworkMgr(sdbusplus::bus::bus& bus, sdeventplus::Event& event,
+    HypNetworkMgr(sdbusplus::bus_t& bus, sdeventplus::Event& event,
                   const char* path) :
         bus(bus),
         event(event), objectPath(path){};
@@ -141,7 +141,7 @@
     void setBIOSTableAttrs();
 
     /** @brief sdbusplus DBus bus connection. */
-    sdbusplus::bus::bus& bus;
+    sdbusplus::bus_t& bus;
 
     /**  sdevent Event handle. */
     sdeventplus::Event& event;
diff --git a/src/ibm/hypervisor-network-mgr-src/hyp_network_manager_main.cpp b/src/ibm/hypervisor-network-mgr-src/hyp_network_manager_main.cpp
index eed841a..d28ca11 100644
--- a/src/ibm/hypervisor-network-mgr-src/hyp_network_manager_main.cpp
+++ b/src/ibm/hypervisor-network-mgr-src/hyp_network_manager_main.cpp
@@ -12,7 +12,7 @@
     auto bus = sdbusplus::bus::new_default();
 
     // Add sdbusplus ObjectManager
-    sdbusplus::server::manager::manager objManager(bus, DEFAULT_HYP_NW_OBJPATH);
+    sdbusplus::server::manager_t objManager(bus, DEFAULT_HYP_NW_OBJPATH);
 
     // Get default event loop
     auto event = sdeventplus::Event::get_default();
diff --git a/src/ibm/hypervisor-network-mgr-src/hyp_sys_config.hpp b/src/ibm/hypervisor-network-mgr-src/hyp_sys_config.hpp
index 7d89d82..f9f7d74 100644
--- a/src/ibm/hypervisor-network-mgr-src/hyp_sys_config.hpp
+++ b/src/ibm/hypervisor-network-mgr-src/hyp_sys_config.hpp
@@ -16,7 +16,7 @@
 using SysConfigIntf =
     sdbusplus::xyz::openbmc_project::Network::server::SystemConfiguration;
 
-using Iface = sdbusplus::server::object::object<SysConfigIntf>;
+using Iface = sdbusplus::server::object_t<SysConfigIntf>;
 
 class HypNetworkMgr; // forward declaration of network manager.
 
@@ -40,7 +40,7 @@
      *  @param[in] objPath - Path to attach at.
      *  @param[in] parent - Parent object.
      */
-    HypSysConfig(sdbusplus::bus::bus& bus, const std::string& objPath,
+    HypSysConfig(sdbusplus::bus_t& bus, const std::string& objPath,
                  HypNetworkMgr& parent) :
         Iface(bus, objPath.c_str(), Iface::action::defer_emit),
         bus(bus), manager(parent){};
@@ -66,7 +66,7 @@
     void setHostNameInBios(const std::string& name);
 
     /** @brief Persistent sdbusplus DBus bus connection. */
-    sdbusplus::bus::bus& bus;
+    sdbusplus::bus_t& bus;
 
     /** @brief Hyp Network Manager object. */
     HypNetworkMgr& manager;
diff --git a/src/ipaddress.cpp b/src/ipaddress.cpp
index 0af0756..ee87d6c 100644
--- a/src/ipaddress.cpp
+++ b/src/ipaddress.cpp
@@ -18,7 +18,7 @@
 using NotAllowed = sdbusplus::xyz::openbmc_project::Common::Error::NotAllowed;
 using Reason = xyz::openbmc_project::Common::NotAllowed::REASON;
 
-IPAddress::IPAddress(sdbusplus::bus::bus& bus, const char* objPath,
+IPAddress::IPAddress(sdbusplus::bus_t& bus, const char* objPath,
                      EthernetInterface& parent, IP::Protocol type,
                      const std::string& ipaddress, IP::AddressOrigin origin,
                      uint8_t prefixLength, const std::string& gateway) :
diff --git a/src/ipaddress.hpp b/src/ipaddress.hpp
index 3ed551a..b78b677 100644
--- a/src/ipaddress.hpp
+++ b/src/ipaddress.hpp
@@ -11,7 +11,7 @@
 namespace network
 {
 
-using IPIfaces = sdbusplus::server::object::object<
+using IPIfaces = sdbusplus::server::object_t<
     sdbusplus::xyz::openbmc_project::Network::server::IP,
     sdbusplus::xyz::openbmc_project::Object::server::Delete>;
 
@@ -45,7 +45,7 @@
      *  @param[in] prefixLength - Length of prefix.
      *  @param[in] gateway - gateway address.
      */
-    IPAddress(sdbusplus::bus::bus& bus, const char* objPath,
+    IPAddress(sdbusplus::bus_t& bus, const char* objPath,
               EthernetInterface& parent, IP::Protocol type,
               const std::string& ipAddress, IP::AddressOrigin origin,
               uint8_t prefixLength, const std::string& gateway);
diff --git a/src/neighbor.cpp b/src/neighbor.cpp
index c1f8fac..e35d262 100644
--- a/src/neighbor.cpp
+++ b/src/neighbor.cpp
@@ -85,7 +85,7 @@
     return neighbors;
 }
 
-Neighbor::Neighbor(sdbusplus::bus::bus& bus, const char* objPath,
+Neighbor::Neighbor(sdbusplus::bus_t& bus, const char* objPath,
                    EthernetInterface& parent, const std::string& ipAddress,
                    const std::string& macAddress, State state) :
     NeighborObj(bus, objPath, NeighborObj::action::defer_emit),
diff --git a/src/neighbor.hpp b/src/neighbor.hpp
index cca9c11..26859c3 100644
--- a/src/neighbor.hpp
+++ b/src/neighbor.hpp
@@ -22,7 +22,7 @@
 
 using NeighborIntf = sdbusplus::xyz::openbmc_project::Network::server::Neighbor;
 
-using NeighborObj = sdbusplus::server::object::object<
+using NeighborObj = sdbusplus::server::object_t<
     NeighborIntf, sdbusplus::xyz::openbmc_project::Object::server::Delete>;
 
 class EthernetInterface;
@@ -80,7 +80,7 @@
      *  @param[in] macAddress - Low level MAC address.
      *  @param[in] state - The state of the neighbor entry.
      */
-    Neighbor(sdbusplus::bus::bus& bus, const char* objPath,
+    Neighbor(sdbusplus::bus_t& bus, const char* objPath,
              EthernetInterface& parent, const std::string& ipAddress,
              const std::string& macAddress, State state);
 
diff --git a/src/network_manager.cpp b/src/network_manager.cpp
index ff41144..6e7deeb 100644
--- a/src/network_manager.cpp
+++ b/src/network_manager.cpp
@@ -40,7 +40,7 @@
 using namespace sdbusplus::xyz::openbmc_project::Common::Error;
 using Argument = xyz::openbmc_project::Common::InvalidArgument;
 
-Manager::Manager(sdbusplus::bus::bus& bus, const char* objPath,
+Manager::Manager(sdbusplus::bus_t& bus, const char* objPath,
                  const std::string& path) :
     details::VLANCreateIface(bus, objPath,
                              details::VLANCreateIface::action::defer_emit),
@@ -291,7 +291,7 @@
                                           NETWORKD_INTERFACE, "Reload");
         bus.call_noreply(method);
     }
-    catch (const sdbusplus::exception::exception& ex)
+    catch (const sdbusplus::exception_t& ex)
     {
         log<level::ERR>("Failed to reload configuration",
                         entry("ERR=%s", ex.what()));
diff --git a/src/network_manager.hpp b/src/network_manager.hpp
index f574891..7ca9939 100644
--- a/src/network_manager.hpp
+++ b/src/network_manager.hpp
@@ -29,7 +29,7 @@
 {
 
 template <typename T, typename U>
-using ServerObject = typename sdbusplus::server::object::object<T, U>;
+using ServerObject = typename sdbusplus::server::object_t<T, U>;
 
 using VLANCreateIface = details::ServerObject<
     sdbusplus::xyz::openbmc_project::Network::VLAN::server::Create,
@@ -55,8 +55,7 @@
      *  @param[in] objPath - Path to attach at.
      *  @param[in] dir - Network Configuration directory path.
      */
-    Manager(sdbusplus::bus::bus& bus, const char* objPath,
-            const std::string& dir);
+    Manager(sdbusplus::bus_t& bus, const char* objPath, const std::string& dir);
 
     ObjectPath vlan(IntfName interfaceName, uint32_t id) override;
 
@@ -173,7 +172,7 @@
 
   protected:
     /** @brief Persistent sdbusplus DBus bus connection. */
-    sdbusplus::bus::bus& bus;
+    sdbusplus::bus_t& bus;
 
     /** @brief Persistent map of EthernetInterface dbus objects and their names
      */
diff --git a/src/network_manager_main.cpp b/src/network_manager_main.cpp
index 349c2ea..802b7d6 100644
--- a/src/network_manager_main.cpp
+++ b/src/network_manager_main.cpp
@@ -51,10 +51,10 @@
 std::unique_ptr<Timer> reloadTimer = nullptr;
 
 #ifdef SYNC_MAC_FROM_INVENTORY
-std::unique_ptr<sdbusplus::bus::match::match> EthInterfaceMatch = nullptr;
+std::unique_ptr<sdbusplus::bus::match_t> EthInterfaceMatch = nullptr;
 std::vector<std::string> first_boot_status;
 
-bool setInventoryMACOnSystem(sdbusplus::bus::bus& bus,
+bool setInventoryMACOnSystem(sdbusplus::bus_t& bus,
                              const nlohmann::json& configJson,
                              const std::string& intfname)
 {
@@ -104,13 +104,13 @@
 }
 
 // register the macthes to be monitored from inventory manager
-void registerSignals(sdbusplus::bus::bus& bus, const nlohmann::json& configJson)
+void registerSignals(sdbusplus::bus_t& bus, const nlohmann::json& configJson)
 {
     log<level::INFO>("Registering the Inventory Signals Matcher");
 
-    static std::unique_ptr<sdbusplus::bus::match::match> MacAddressMatch;
+    static std::unique_ptr<sdbusplus::bus::match_t> MacAddressMatch;
 
-    auto callback = [&](sdbusplus::message::message& m) {
+    auto callback = [&](sdbusplus::message_t& m) {
         std::map<DbusObjectPath,
                  std::map<DbusInterface, std::variant<PropertyValue>>>
             interfacesProperties;
@@ -148,7 +148,7 @@
         }
     };
 
-    MacAddressMatch = std::make_unique<sdbusplus::bus::match::match>(
+    MacAddressMatch = std::make_unique<sdbusplus::bus::match_t>(
         bus,
         "interface='org.freedesktop.DBus.ObjectManager',type='signal',"
         "member='InterfacesAdded',path='/xyz/openbmc_project/"
@@ -156,10 +156,10 @@
         callback);
 }
 
-void watchEthernetInterface(sdbusplus::bus::bus& bus,
+void watchEthernetInterface(sdbusplus::bus_t& bus,
                             const nlohmann::json& configJson)
 {
-    auto mycallback = [&](sdbusplus::message::message& m) {
+    auto mycallback = [&](sdbusplus::message_t& m) {
         std::map<DbusObjectPath,
                  std::map<DbusInterface, std::variant<PropertyValue>>>
             interfacesProperties;
@@ -221,7 +221,7 @@
             log<level::INFO>(
                 "First boot file is not present, check VPD for MAC");
             phosphor::network::EthInterfaceMatch = std::make_unique<
-                sdbusplus::bus::match::match>(
+                sdbusplus::bus::match_t>(
                 bus,
                 "interface='org.freedesktop.DBus.ObjectManager',type='signal',"
                 "member='InterfacesAdded',path='/xyz/openbmc_project/network'",
@@ -300,7 +300,7 @@
     bus.attach_event(eventPtr.get(), SD_EVENT_PRIORITY_NORMAL);
 
     // Add sdbusplus Object Manager for the 'root' path of the network manager.
-    sdbusplus::server::manager::manager objManager(bus, DEFAULT_OBJPATH);
+    sdbusplus::server::manager_t objManager(bus, DEFAULT_OBJPATH);
     bus.request_name(DEFAULT_BUSNAME);
 
     phosphor::network::manager = std::make_unique<phosphor::network::Manager>(
diff --git a/src/system_configuration.cpp b/src/system_configuration.cpp
index b430bfc..e1bbf2e 100644
--- a/src/system_configuration.cpp
+++ b/src/system_configuration.cpp
@@ -25,7 +25,7 @@
 using SystemConfigIntf =
     sdbusplus::xyz::openbmc_project::Network::server::SystemConfiguration;
 
-SystemConfiguration::SystemConfiguration(sdbusplus::bus::bus& bus,
+SystemConfiguration::SystemConfiguration(sdbusplus::bus_t& bus,
                                          const std::string& objPath) :
     Iface(bus, objPath.c_str(), Iface::action::defer_emit),
     bus(bus)
@@ -72,7 +72,7 @@
         reply.read(name);
         return std::get<std::string>(name);
     }
-    catch (const sdbusplus::exception::exception& ex)
+    catch (const sdbusplus::exception_t& ex)
     {
         log<level::ERR>(
             "Failed to get the hostname from systemd-hostnamed service",
diff --git a/src/system_configuration.hpp b/src/system_configuration.hpp
index 0bc1dab..f5289ce 100644
--- a/src/system_configuration.hpp
+++ b/src/system_configuration.hpp
@@ -13,7 +13,7 @@
 using SystemConfigIntf =
     sdbusplus::xyz::openbmc_project::Network::server::SystemConfiguration;
 
-using Iface = sdbusplus::server::object::object<SystemConfigIntf>;
+using Iface = sdbusplus::server::object_t<SystemConfigIntf>;
 
 class Manager; // forward declaration of network manager.
 
@@ -37,7 +37,7 @@
      *  @param[in] objPath - Path to attach at.
      *  @param[in] parent - Parent object.
      */
-    SystemConfiguration(sdbusplus::bus::bus& bus, const std::string& objPath);
+    SystemConfiguration(sdbusplus::bus_t& bus, const std::string& objPath);
 
     /** @brief set the hostname of the system.
      *  @param[in] name - host name of the system.
@@ -51,7 +51,7 @@
     std::string getHostNameFromSystem() const;
 
     /** @brief Persistent sdbusplus DBus bus connection. */
-    sdbusplus::bus::bus& bus;
+    sdbusplus::bus_t& bus;
 };
 
 } // namespace network
diff --git a/src/util.cpp b/src/util.cpp
index c331463..3bd3806 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -541,8 +541,7 @@
     "xyz.openbmc_project.Inventory.Item.NetworkInterface";
 constexpr auto invRoot = "/xyz/openbmc_project/inventory";
 
-ether_addr getfromInventory(sdbusplus::bus::bus& bus,
-                            const std::string& intfName)
+ether_addr getfromInventory(sdbusplus::bus_t& bus, const std::string& intfName)
 {
 
     std::string interfaceName = intfName;
diff --git a/src/util.hpp b/src/util.hpp
index 804d492..c463ce0 100644
--- a/src/util.hpp
+++ b/src/util.hpp
@@ -36,8 +36,7 @@
  *  @param[in] bus - DBUS Bus Object.
  *  @param[in] intfName - Interface name
  */
-ether_addr getfromInventory(sdbusplus::bus::bus& bus,
-                            const std::string& intfName);
+ether_addr getfromInventory(sdbusplus::bus_t& bus, const std::string& intfName);
 
 /** @brief Converts the given mac address into byte form
  *  @param[in] str - The mac address in human readable form
diff --git a/src/vlan_interface.cpp b/src/vlan_interface.cpp
index b893be4..6e37283 100644
--- a/src/vlan_interface.cpp
+++ b/src/vlan_interface.cpp
@@ -21,10 +21,10 @@
 using namespace phosphor::logging;
 using namespace sdbusplus::xyz::openbmc_project::Common::Error;
 
-VlanInterface::VlanInterface(sdbusplus::bus::bus& bus,
-                             const std::string& objPath, DHCPConf dhcpEnabled,
-                             bool nicEnabled, uint32_t vlanID,
-                             EthernetInterface& intf, Manager& parent) :
+VlanInterface::VlanInterface(sdbusplus::bus_t& bus, const std::string& objPath,
+                             DHCPConf dhcpEnabled, bool nicEnabled,
+                             uint32_t vlanID, EthernetInterface& intf,
+                             Manager& parent) :
     VlanIface(bus, objPath.c_str()),
     DeleteIface(bus, objPath.c_str()),
     EthernetInterface(bus, objPath, dhcpEnabled, parent, true, nicEnabled),
diff --git a/src/vlan_interface.hpp b/src/vlan_interface.hpp
index c003056..953a01b 100644
--- a/src/vlan_interface.hpp
+++ b/src/vlan_interface.hpp
@@ -46,7 +46,7 @@
      *
      *  This constructor is called during loading the VLAN Interface
      */
-    VlanInterface(sdbusplus::bus::bus& bus, const std::string& objPath,
+    VlanInterface(sdbusplus::bus_t& bus, const std::string& objPath,
                   DHCPConf dhcpEnabled, bool nicEnabled, uint32_t vlanID,
                   EthernetInterface& intf, Manager& parent);