using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HBLConsole.Service
{
    public static class ExpandMethod
    {
        public static int GetIndex(this bool[] obj, bool value)
        {
            if (obj == null) return -1;
            return Array.FindIndex(obj, p => p == value);
        }

        public static int GetIndex(this string[] obj, string value)
        {
            if (obj == null || value == null) return -1;
            return Array.FindIndex(obj, p => p == value && p.Length > 0);
        }
    }
}
