Move another constructor to the header.

Also, don't mark Properties() constructors as explicit.
This commit is contained in:
Jacob 2024-05-16 10:51:42 +02:00
parent b206aa3ea7
commit 3e7a63e282
2 changed files with 2 additions and 6 deletions

View file

@ -439,12 +439,12 @@ namespace docpp {
* @brief Construct a new Properties object
* @param properties The properties to set
*/
explicit Properties(const std::vector<Property>& properties);
Properties(const std::vector<Property>& properties) : properties(properties) {};
/**
* @brief Construct a new Properties object
* @param property The property to add
*/
explicit Properties(const Property& property) : properties({property}) {};
Properties(const Property& property) : properties({property}) {};
/**
* @brief Construct a new Properties object
*/

View file

@ -58,10 +58,6 @@ void docpp::HTML::Property::set(const std::pair<std::string, std::string>& prope
this->property = property;
}
docpp::HTML::Properties::Properties(const std::vector<docpp::HTML::Property>& properties) {
this->set(properties);
}
docpp::HTML::Properties docpp::HTML::Properties::operator=(const docpp::HTML::Property& property) {
this->properties = {property};
return *this;