Add more datatypes
ClosedPublic

Authored by lbeltrame on Apr 5 2018, 9:46 PM.

Details

Summary

This patch adds the following types:

  • TouristAttraction
  • FoodEstablishment

I added FoodEstablishment because otherwise getting more specific types
is a mess with schema.org's complex inheritance. This one is the most generic
type for that kind of stuff.

Test Plan

Compile only, but some of the other Places don't have tests yet.

Diff Detail

Repository
R1003 KItinerary: Travel Reservation handling library
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
lbeltrame created this revision.Apr 5 2018, 9:46 PM
Restricted Application added a project: KDE PIM. · View Herald TranscriptApr 5 2018, 9:46 PM
Restricted Application added a subscriber: KDE PIM. · View Herald Transcript
lbeltrame requested review of this revision.Apr 5 2018, 9:46 PM
vkrause accepted this revision.Apr 6 2018, 8:07 AM

Simplifying the inheritance is perfectly fine, we do that in a number of other places too (e.g. we don't use "Thing"), let's just make this as complex as absolutely necessary.

Regarding tests, that's fine too, we don't need to test every single property access, as this is all the same code anyway. The purpose of datatypetest.cpp is primarily to ensure that the memory management of the polymorphic value types cannot be broken by "creative use" :)

This revision is now accepted and ready to land.Apr 6 2018, 8:07 AM
This revision was automatically updated to reflect the committed changes.