/// <summary> /// Generates schema for given .NET Type /// <paramref name="includeOnlyDataContractMembers"/> indicates if only classes with DataContractAttribute and properties marked with DataMemberAttribute should be returned /// </summary> public static string GenerateSchema(Type type, bool includeOnlyDataContractMembers) { var reader = new ReflectionSchemaBuilder(new AvroSerializerSettings(includeOnlyDataContractMembers)).BuildSchema(type); return(reader.ToString()); }
public static string GenerateSchema(Type type, bool usePropertyNameAsAlias = false, bool includeOnlyDataContractMembers = false) { var reader = new ReflectionSchemaBuilder(new AvroSerializerSettings(usePropertyNameAsAlias, includeOnlyDataContractMembers)).BuildSchema(type); return(reader.ToString()); }
/// <summary> /// Generates schema for given .NET Type /// </summary> public static string GenerateSchema(Type type) { var reader = new ReflectionSchemaBuilder(new AvroSerializerSettings(false)).BuildSchema(type); return(reader.ToString()); }