From 80179d0d487623a5bbd8b49a9ef8a32a5302cd9a Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Thu, 10 Jun 2021 16:35:37 +0200 Subject: [PATCH] Cosmetics: snake_case. --- src/bindings/lua/lua_platf.cpp | 4 ++-- src/surf/sg_platf.cpp | 14 +++++++------- src/surf/xml/platf_private.hpp | 8 ++++---- src/surf/xml/surfxml_sax_cb.cpp | 10 +++++----- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/bindings/lua/lua_platf.cpp b/src/bindings/lua/lua_platf.cpp index 1df2436ef5..56eb196c5c 100644 --- a/src/bindings/lua/lua_platf.cpp +++ b/src/bindings/lua/lua_platf.cpp @@ -454,7 +454,7 @@ int console_AS_open(lua_State *L) { simgrid::kernel::routing::ZoneCreationArgs AS; AS.id = id; AS.routing = mode; - simgrid::kernel::routing::NetZoneImpl* new_as = sg_platf_new_Zone_begin(&AS); + simgrid::kernel::routing::NetZoneImpl* new_as = sg_platf_new_zone_begin(&AS); /* Build a Lua representation of the new AS on the stack */ lua_newtable(L); @@ -471,7 +471,7 @@ int console_AS_open(lua_State *L) { int console_AS_seal(lua_State*) { XBT_DEBUG("Sealing AS"); - sg_platf_new_Zone_seal(); + sg_platf_new_zone_seal(); return 0; } diff --git a/src/surf/sg_platf.cpp b/src/surf/sg_platf.cpp index c796d6a48b..ae6e3db983 100644 --- a/src/surf/sg_platf.cpp +++ b/src/surf/sg_platf.cpp @@ -446,10 +446,10 @@ void sg_platf_new_route(simgrid::kernel::routing::RouteCreationArgs* route) route->symmetrical); } -void sg_platf_new_bypassRoute(simgrid::kernel::routing::RouteCreationArgs* bypassRoute) +void sg_platf_new_bypass_route(simgrid::kernel::routing::RouteCreationArgs* route) { - current_routing->add_bypass_route(bypassRoute->src, bypassRoute->dst, bypassRoute->gw_src, bypassRoute->gw_dst, - bypassRoute->link_list, bypassRoute->symmetrical); + current_routing->add_bypass_route(route->src, route->dst, route->gw_src, route->gw_dst, route->link_list, + route->symmetrical); } void sg_platf_new_actor(simgrid::kernel::routing::ActorCreationArgs* actor) @@ -565,13 +565,13 @@ sg_platf_create_zone(const simgrid::kernel::routing::ZoneCreationArgs* zone) * @brief Add a Zone to the platform * * Add a new autonomous system to the platform. Any elements (such as host, router or sub-Zone) added after this call - * and before the corresponding call to sg_platf_new_Zone_seal() will be added to this Zone. + * and before the corresponding call to sg_platf_new_zone_seal() will be added to this Zone. * * Once this function was called, the configuration concerning the used models cannot be changed anymore. * * @param zone the parameters defining the Zone to build. */ -simgrid::kernel::routing::NetZoneImpl* sg_platf_new_Zone_begin(const simgrid::kernel::routing::ZoneCreationArgs* zone) +simgrid::kernel::routing::NetZoneImpl* sg_platf_new_zone_begin(const simgrid::kernel::routing::ZoneCreationArgs* zone) { zone_cluster.routing = zone->routing; current_routing = sg_platf_create_zone(zone); @@ -579,7 +579,7 @@ simgrid::kernel::routing::NetZoneImpl* sg_platf_new_Zone_begin(const simgrid::ke return current_routing; } -void sg_platf_new_Zone_set_properties(const std::unordered_map& props) +void sg_platf_new_zone_set_properties(const std::unordered_map& props) { xbt_assert(current_routing, "Cannot set properties of the current Zone: none under construction"); @@ -592,7 +592,7 @@ void sg_platf_new_Zone_set_properties(const std::unordered_map& props); -XBT_PUBLIC void sg_platf_new_Zone_seal(); // That Zone is fully described +sg_platf_new_zone_begin(const simgrid::kernel::routing::ZoneCreationArgs* zone); // Begin description of new Zone +XBT_PUBLIC void sg_platf_new_zone_set_properties(const std::unordered_map& props); +XBT_PUBLIC void sg_platf_new_zone_seal(); // That Zone is fully described XBT_PUBLIC void sg_platf_new_host_begin(const simgrid::kernel::routing::HostCreationArgs* host); // Add a host to the current Zone @@ -204,7 +204,7 @@ sg_platf_new_router(const std::string&, const std::string& coords); XBT_PUBLIC void sg_platf_new_cabinet(const simgrid::kernel::routing::CabinetCreationArgs* cabinet); // Add a cabinet to the current Zone XBT_PUBLIC void sg_platf_new_route(simgrid::kernel::routing::RouteCreationArgs* route); // Add a route -XBT_PUBLIC void sg_platf_new_bypassRoute(simgrid::kernel::routing::RouteCreationArgs* bypassroute); // Add a bypassRoute +XBT_PUBLIC void sg_platf_new_bypass_route(simgrid::kernel::routing::RouteCreationArgs* route); // Add a bypass route XBT_PUBLIC void sg_platf_new_trace(simgrid::kernel::routing::ProfileCreationArgs* trace); diff --git a/src/surf/xml/surfxml_sax_cb.cpp b/src/surf/xml/surfxml_sax_cb.cpp index b95eb0b77c..58eefa276e 100644 --- a/src/surf/xml/surfxml_sax_cb.cpp +++ b/src/surf/xml/surfxml_sax_cb.cpp @@ -615,7 +615,7 @@ void ETag_surfxml_bypassRoute(){ route.link_list.swap(parsed_link_list); - sg_platf_new_bypassRoute(&route); + sg_platf_new_bypass_route(&route); } void ETag_surfxml_bypassASroute() @@ -639,7 +639,7 @@ void ETag_surfxml_bypassZoneRoute() ASroute.gw_src = sg_netpoint_by_name_or_null(A_surfxml_bypassZoneRoute_gw___src); ASroute.gw_dst = sg_netpoint_by_name_or_null(A_surfxml_bypassZoneRoute_gw___dst); - sg_platf_new_bypassRoute(&ASroute); + sg_platf_new_bypass_route(&ASroute); } void ETag_surfxml_trace(){ @@ -701,14 +701,14 @@ void STag_surfxml_zone() simgrid::kernel::routing::ZoneCreationArgs zone; zone.id = A_surfxml_zone_id; zone.routing = A_surfxml_zone_routing; - sg_platf_new_Zone_begin(&zone); + sg_platf_new_zone_begin(&zone); } void ETag_surfxml_zone() { - sg_platf_new_Zone_set_properties(property_sets.back()); + sg_platf_new_zone_set_properties(property_sets.back()); property_sets.pop_back(); - sg_platf_new_Zone_seal(); + sg_platf_new_zone_seal(); } void STag_surfxml_config() -- 2.20.1