Migrate to new tribufu project structure

This commit is contained in:
Guilherme Werner 2026-06-21 12:07:08 -03:00
parent be25ee8fe3
commit 6ef2762a64
114 changed files with 35 additions and 26 deletions

View file

@ -0,0 +1,20 @@
// Copyright (c) Tribufu. All Rights Reserved.
// SPDX-License-Identifier: UNLICENSED
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using System;
using System.Collections.Generic;
using System.Linq;
namespace Tribufu.Serialization
{
public class BaseClassFirstContractResolver : DefaultContractResolver
{
protected override IList<JsonProperty> CreateProperties(Type type, MemberSerialization memberSerialization)
{
var props = base.CreateProperties(type, memberSerialization);
return props.OrderBy(p => { return p.DeclaringType == type ? 1 : 0; }).ToList();
}
}
}