WebApiContrib / WebApiContrib.Formatting.ProtoBuf

Web API formatter based on ProtoBuf
http://nuget.org/packages/WebApiContrib.Formatting.ProtoBuf
MIT License
30 stars 19 forks source link

Implemented CanReadTypeCore() #7

Closed bastianeicher closed 8 years ago

bastianeicher commented 8 years ago

Determine serializability by looking for ProtoContractAttribute

filipw commented 8 years ago

thanks

bacobart commented 8 years ago

Shouldn't you also check for DataContractAttribute?

filipw commented 8 years ago

no it's not mandatory

bacobart commented 8 years ago

why not? before classes decorated with DataContract instead of ProtoContract could also be serialized with protobuf, now they are not supported anymore?

bastianeicher commented 8 years ago

I think this is just a small misunderstanding.

@bacobart I believe you are suggesting CanReadTypeCore() should return true if DataContract or ProtoContract is present. Sounds like a good idea, I simply forgot about DataContract in my pull request.

@filipw I believe you understood @bacobart to be suggesting checking if DataContract and ProtoContract are present.