You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Dec 8, 2022. It is now read-only.
Thanks for the question @tornewuff. Would you mind asking this as a question on StackOverflow and I'll be happy to answer there?
If not, you should check out the Custom Alias Properties example in the documentation. If that clears it up, no need for the StackOverflow question. If not, I'm happy to answer there.
Ah, I didn't read that example yet, oops. Would it be worth having the alternate getter/setter implemented in the library somehow, to save having to add it to each class? Something like "_message_id_string = True" seems nice and self-documenting, though I guess it's still only one line to reuse the same functions in all entity classes: "id = property(StringIdGet, StringIdSet)"
Yep, issue #21 has asked for this and I think your suggestion perfectly crystallizes this :)
Thanks for the insight.
I don't like _message_id_string = True approach because less is more when we're talking about expanding the interface of what people have to deal with. But added more utility methods (e.g. StringIdGet and StringIdSet) is totally do-able.
A number of my model types have string IDs. Is there a way to use these as the value of the "id" property?
The text was updated successfully, but these errors were encountered: