I am working on a libray that runs a game. I've got a type
Card
Card
. it stores a card. I want EFCore to know how to store a card. so i wrote
CardToStringConverter
CardToStringConverter
(see the gist)
I want EFCore to use this whenever it sees Card.
I am writing a method that will add this converter (and any other i build) to properties that store a Card (other the other types i convert),
AddConverters
AddConverters
(see the gist)
The issue is collections. If i am storing a List<Card> this method wont work. Chat suggests this is not possible, but it can be kind of stupid for use cases like this, so i thought i would ask some real people with real experience.
i suspect i will have to create a
CardStorage
CardStorage
class that just stores a the string as an identifier, but i am trying to avoid that.