using System;
using System.Collections;
using System.Collections.Generic;
using System.Reflection;
using System.Text;

namespace Apewer
{

    /// <summary>使用 Json.Parse 方法将实例转为 Json 的检查器。</summary>
    /// <remarks>当实例实现 IToJson 时,此接口中的方法可能无效。</remarks>
    public interface IToJsonChecker
    {

        /// <summary>转换为 Json 时,包含此元素。</summary>
        public bool WithItemInJson(IList list, object item);

        /// <summary>转换为 Json 时,包含此元素。</summary>
        public bool WithPropertyInJson(object entity, PropertyInfo property, object value);

        /// <summary>转换为 Json 时,包含此元素。</summary>
        public bool WithPropertyInJson(IDictionary dictionary, string key, object value);

    }

}