Enable Metadata\MetadataFactory::setIncludeInterfaces()
lstrojny opened this issue · 2 comments
lstrojny commented
Any particular reason why Metadata\MetadataFactory::setIncludeInterfaces()
is not enabled per default and/or no setting exists. Would be cool to use interfaces for shared metadata.
lstrojny commented
I realized this might sound demanding, which is not what I meant. Much rather: has this been considered before?
goetas commented
jms serializer uses the same strategy, and since this library is just a plugin for the serializer, it has to follow the same.
On the other side, in jms that decision has been taken to avoid some unexpected behaviors when defining metadata (makes harder to override metadata). It has been used a simple rule "metadata are per-class" anything else (interfaces, traits) is just ignored.