getStorageList(std::map<std::string, Storage*>* whereTo)
{
for (auto const& s : simgrid::s4u::Engine::getInstance()->getAllStorages())
- whereTo->insert({s->getName(), s});
+ whereTo->insert({s->get_name(), s});
}
Storage::Storage(std::string name, surf::StorageImpl* pimpl) : pimpl_(pimpl), name_(name)
return Engine::getInstance()->storageByNameOrNull(name);
}
-const std::string& Storage::getName() const
+const std::string& Storage::get_name() const
{
return name_;
}
-const char* Storage::getCname() const
+const char* Storage::get_cname() const
{
return name_.c_str();
}
} /* namespace simgrid */
/* **************************** Public C interface *************************** */
-SG_BEGIN_DECL()
+
/** @addtogroup sg_storage_management
* (#sg_storage_t) and the functions for managing it.
*/
const char* sg_storage_get_name(sg_storage_t storage)
{
xbt_assert((storage != nullptr), "Invalid parameters");
- return storage->getCname();
+ return storage->get_cname();
}
const char* sg_storage_get_host(sg_storage_t storage)
{
xbt_assert((storage != nullptr), "Invalid parameters");
- return storage->getHost()->getCname();
+ return storage->getHost()->get_cname();
}
/** \ingroup sg_storage_management
* \param name a property name
* \param value what to change the property to
*/
-void sg_storage_set_property_value(sg_storage_t storage, const char* name, char* value)
+void sg_storage_set_property_value(sg_storage_t storage, const char* name, const char* value)
{
storage->setProperty(name, value);
}
{
return storage->write(size);
}
-SG_END_DECL()