diff --git a/include/faker-cxx/types/Country.h b/include/faker-cxx/types/Country.h index 3c3ffbff..da7563e4 100644 --- a/include/faker-cxx/types/Country.h +++ b/include/faker-cxx/types/Country.h @@ -30,13 +30,14 @@ enum class Country Norway, Japan, Portugal, + Hungary, }; const std::vector countries{ - Country::Usa, Country::England, Country::Poland, Country::Italy, Country::France, Country::Germany, - Country::Russia, Country::Romania, Country::India, Country::Finland, Country::Nepal, Country::Spain, - Country::Turkey, Country::Czech, Country::Slovakia, Country::Ukraine, Country::Denmark, Country::Sweden, - Country::Brazil, Country::Norway, Country::Japan, Country::Portugal}; + Country::Usa, Country::England, Country::Poland, Country::Italy, Country::France, Country::Germany, + Country::Russia, Country::Romania, Country::India, Country::Finland, Country::Nepal, Country::Spain, + Country::Turkey, Country::Czech, Country::Slovakia, Country::Ukraine, Country::Denmark, Country::Sweden, + Country::Brazil, Country::Norway, Country::Japan, Country::Portugal, Country::Hungary}; inline std::string toString(Country country) { @@ -48,7 +49,7 @@ inline std::string toString(Country country) {Country::Turkey, "Turkey"}, {Country::Czech, "Czech"}, {Country::Slovakia, "Slovakia"}, {Country::Ukraine, "Ukraine"}, {Country::Denmark, "Denmark"}, {Country::Sweden, "Sweden"}, {Country::Brazil, "Brazil"}, {Country::Norway, "Norway"}, {Country::Japan, "Japan"}, - {Country::Portugal, "Portugal"}, + {Country::Portugal, "Portugal"}, {Country::Hungary, "Hungary"}, }; return countryToStringMapping.at(country); diff --git a/src/modules/person/Person.cpp b/src/modules/person/Person.cpp index 92743527..04e40c3e 100644 --- a/src/modules/person/Person.cpp +++ b/src/modules/person/Person.cpp @@ -14,6 +14,7 @@ #include "data/Gender.h" #include "data/germany/GermanPeopleNames.h" #include "data/Hobbies.h" +#include "data/hungary/HungarianPeopleNames.h" #include "data/india/IndianPeopleNames.h" #include "data/italy/ItalianPeopleNames.h" #include "data/japan/JapanesePeopleNames.h" @@ -54,6 +55,7 @@ const std::map countryToPeopleNamesMapping{ {Country::Sweden, swedishPeopleNames}, {Country::Usa, usaPeopleNames}, {Country::Brazil, brazilianPeopleNames}, {Country::Norway, norwegianPeopleNames}, {Country::Japan, japanesePeopleNames}, {Country::Portugal, portuguesePeopleNames}, + {Country::Hungary, hungarianPeopleNames}, }; std::string middleNameForCountry(Country country, std::optional sex); diff --git a/src/modules/person/PersonTest.cpp b/src/modules/person/PersonTest.cpp index e7846eb1..bbcf5446 100644 --- a/src/modules/person/PersonTest.cpp +++ b/src/modules/person/PersonTest.cpp @@ -13,6 +13,7 @@ #include "data/Gender.h" #include "data/germany/GermanPeopleNames.h" #include "data/Hobbies.h" +#include "data/hungary/HungarianPeopleNames.h" #include "data/india/IndianPeopleNames.h" #include "data/italy/ItalianPeopleNames.h" #include "data/japan/JapanesePeopleNames.h" @@ -54,6 +55,7 @@ const std::map countryToPeopleNamesMapping{ {Country::Sweden, swedishPeopleNames}, {Country::Usa, usaPeopleNames}, {Country::Brazil, brazilianPeopleNames}, {Country::Norway, norwegianPeopleNames}, {Country::Japan, japanesePeopleNames}, {Country::Portugal, portuguesePeopleNames}, + {Country::Hungary, hungarianPeopleNames}, }; const std::map generatedTestName{ @@ -68,6 +70,7 @@ const std::map generatedTestName{ {Country::Sweden, "shouldGenerateSwedishName"}, {Country::Usa, "shouldGenerateAmericanName"}, {Country::Brazil, "shouldGenerateBrazilianName"}, {Country::Norway, "shouldGenerateNorwegianName"}, {Country::Japan, "shouldGenerateJapaneseName"}, {Country::Portugal, "shouldGeneratePortugueseName"}, + {Country::Hungary, "shouldGenerateHungarianName"}, }; } diff --git a/src/modules/person/data/hungary/HungarianFirstNames.h b/src/modules/person/data/hungary/HungarianFirstNames.h new file mode 100644 index 00000000..84384542 --- /dev/null +++ b/src/modules/person/data/hungary/HungarianFirstNames.h @@ -0,0 +1,33 @@ +#pragma once + +#include +#include + +namespace faker +{ +const std::vector hungarianMalesFirstNames = { + "Bence", "Máté", "Dominik", "Levente", "Noel", "Dániel", "Zalán", "Marcell", "Olivér", + "Ádám", "Milán", "Dávid", "Botond", "Benett", "Áron", "Zsombor", "Balázs", "Márk", + "Péter", "Kristóf", "Zétény", "Nimród", "László", "Benedek", "Tamás", "Gergő", "Patrik", + "Zente", "Bálint", "András", "Zoltán", "Attila", "Barnabás", "Márton", "Hunor", "Kornél", + "Martin", "Ákos", "Gábor", "Alex", "István", "Vince", "Ábel", "Krisztián", "Zsolt", + "János", "Nolen", "Erik", "Bendegúz", "Sándor", "József", "Nándor", "Richárd", "Benjámin", + "Soma", "Ármin", "Csaba", "Kevin", "Róbert", "Ferenc", "Mátyás", "Norbert", "Roland", + "Vencel", "Viktor", "Csongor", "Szabolcs", "Mihály", "Boldizsár", "Benjamin", "Simon", "Gergely", + "Bertalan", "Tibor", "Zénó", "Adrián", "Miklós", "Nikolasz", "Vilmos", "Kende", "Imre", + "Gellért", "Krisztofer", "Donát", "Vendel", "Bende", "Brájen", "Dorián", "Denisz", "Sámuel", + "Noé", "Csanád", "Lajos", "Kolos", "Alexander", "Laurent", "Mirkó", "György", "Nátán", + "Iván"}; + +const std::vector hungarianFemalesFirstNames = { + "Hanna", "Anna", "Zoé", "Léna", "Luca", "Emma", "Zsófia", "Boglárka", "Lili", "Mira", + "Lilien", "Nóra", "Laura", "Lara", "Maja", "Fanni", "Jázmin", "Izabella", "Olívia", "Sára", + "Gréta", "Alíz", "Adél", "Lilla", "Liza", "Flóra", "Dorka", "Zselyke", "Dóra", "Csenge", + "Janka", "Liliána", "Viktória", "Szofia", "Réka", "Panna", "Petra", "Dorina", "Natasa", "Blanka", + "Eszter", "Noémi", "Emília", "Bianka", "Kamilla", "Szófia", "Vivien", "Rebeka", "Elizabet", "Linett", + "Szofi", "Júlia", "Szonja", "Abigél", "Mia", "Bella", "Lia", "Natália", "Tamara", "Lotti", + "Róza", "Amira", "Eliza", "Panka", "Milla", "Zorka", "Hanga", "Nara", "Norina", "Fruzsina", + "Mirella", "Dorottya", "Boróka", "Emili", "Regina", "Johanna", "Alexandra", "Diána", "Elena", "Kinga", + "Hédi", "Borbála", "Emese", "Bíborka", "Barbara", "Letícia", "Lujza", "Zita", "Kincső", "Nina", + "Vanda", "Veronika", "Zara", "Lana", "Lora", "Kiara", "Lívia", "Rozina", "Zejnep", "Virág"}; +} diff --git a/src/modules/person/data/hungary/HungarianLastNames.h b/src/modules/person/data/hungary/HungarianLastNames.h new file mode 100644 index 00000000..9edbbbe5 --- /dev/null +++ b/src/modules/person/data/hungary/HungarianLastNames.h @@ -0,0 +1,19 @@ +#pragma once + +#include +#include + +namespace faker +{ +const std::vector hungarianLastNames = { + "Nagy", "Kovács", "Tóth", "Szabó", "Horváth", "Varga", "Kiss", "Molnár", "Németh", "Farkas", + "Balogh", "Papp", "Takács", "Juhász", "Lakatos", "Mészáros", "Oláh", "Simon", "Rácz", "Fekete", + "Szilágyi", "Török", "Fehér", "Balázs", "Gál", "Kis", "Szűcs", "Kocsis", "Orsós", "Pintér", + "Fodor", "Szalai", "Sipos", "Magyar", "Lukács", "Gulyás", "Biró", "Király", "László", "Katona", + "Jakab", "Bogdán", "Balog", "Sándor", "Boros", "Fazekas", "Kelemen", "Váradi", "Antal", "Somogyi", + "Orosz", "Fülöp", "Veres", "Vincze", "Hegedűs", "Budai", "Deák", "Pap", "Bálint", "Pál", + "Illés", "Vass", "Szőke", "Vörös", "Bognár", "Fábián", "Lengyel", "Bodnár", "Szücs", "Hajdu", + "Halász", "Jónás", "Máté", "Székely", "Kozma", "Gáspár", "Pásztor", "Bakos", "Dudás", "Major", + "Orbán", "Hegedüs", "Virág", "Barna", "Novák", "Soós", "Tamás", "Nemes", "Pataki", "Balla", + "Faragó", "Kerekes", "Borbély", "Barta", "Péter", "Szekeres", "Csonka", "Mezei", "Márton", "Sárközi"}; +} diff --git a/src/modules/person/data/hungary/HungarianPeopleNames.h b/src/modules/person/data/hungary/HungarianPeopleNames.h new file mode 100644 index 00000000..5172feb8 --- /dev/null +++ b/src/modules/person/data/hungary/HungarianPeopleNames.h @@ -0,0 +1,17 @@ +#pragma once + +#include "../NameFormats.h" +#include "../PeopleNames.h" +#include "HungarianFirstNames.h" +#include "HungarianLastNames.h" +#include "HungarianPrefixes.h" + +namespace faker +{ +const NameFormats hungarianPersonNameFormats{{{"{prefix} {firstName} {lastName}", 1}, {"{firstName} {lastName}", 9}}}; + +const PeopleNames hungarianPeopleNames{{hungarianMalesFirstNames, {}, hungarianLastNames, hungarianPrefixes, {}}, + {hungarianFemalesFirstNames, {}, hungarianLastNames, hungarianPrefixes, {}}, + hungarianPersonNameFormats}; + +} diff --git a/src/modules/person/data/hungary/HungarianPrefixes.h b/src/modules/person/data/hungary/HungarianPrefixes.h new file mode 100644 index 00000000..716eb1d2 --- /dev/null +++ b/src/modules/person/data/hungary/HungarianPrefixes.h @@ -0,0 +1,9 @@ +#pragma once + +#include +#include + +namespace faker +{ +const std::vector hungarianPrefixes{"Dr.", "Prof."}; +}