C# DataTable扩展方法

在日常搬砖中,总结了一些简单的扩展方法。

        public static bool IsNullOrEmpty(this DataTable dt)
        {
            return dt == null || dt.Rows.Count <= 0;
        }
        public static bool IsNotEmpty(this DataTable dt)
        {
            return dt.IsNullOrEmpty() == false;
        }