Hey, > This could be solved using polymorphism: CommonsMedia, IRI, etc could simply derive from StringValue. Similarly, Percentage could derive from NumberValue, etc.
That violates Liskov Substitution [0] ;) If we go with this approach, we also should have a SquareValue that derives from RectangleValue, to have the basics covered :D [0] https://en.wikipedia.org/wiki/Liskov_substitution_principle Cheers -- Jeroen De Dauw http://www.bn2vs.com Don't panic. Don't be evil. ~=[,,_,,]:3 --
_______________________________________________ Wikidata-tech mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikidata-tech
