public SerializationRegistry(CborOptions options) { ConverterRegistry = new CborConverterRegistry(options); ObjectMappingRegistry = new ObjectMappingRegistry(this); ObjectMappingConventionRegistry = new ObjectMappingConventionRegistry(); DiscriminatorConventionRegistry = new DiscriminatorConventionRegistry(this); }
public MemberMapping(CborConverterRegistry converterRegistry, IObjectMapping objectMapping, MemberInfo memberInfo, Type memberType) { _objectMapping = objectMapping; _converterRegistry = converterRegistry; MemberInfo = memberInfo; MemberType = memberType; MemberName = null; DefaultValue = (memberType.IsClass || memberType.IsInterface) ? null : Activator.CreateInstance(memberType); }