/// <summary>
        /// Initializes a new instance of the <see cref="SearchForConnections"/> class.
        /// </summary>
        /// <param name="search">The search.</param>
        /// <param name="timeout">The timeout in milliseconds.</param>
        /// <param name="sendInterval">The send interval in milliseconds.</param>
        /// <autogeneratedoc />
        /// TODO Edit XML Comment Template for #ctor
        public SearchForConnections(ConnectionSearchTypes search = ConnectionSearchTypes.All, int timeout = 0, int sendInterval = 100)
        {
            SearchTypes  = search;
            Timeout      = timeout;
            SendInterval = sendInterval;

            serialPortQuery.SerialDeviceDiscovered += SerialDeviceDiscovered;
            serialPortQuery.SerialDeviceExpired    += SerialDeviceExpired;
        }
        /// <summary>
        /// Enumerate all available connections. Note: This method blocks until connections have been enumerated.
        /// </summary>
        /// <param name="autoConnectorSearchTypes">Search filter.</param>
        /// <param name="timeout">The maximum time before failure.</param>
        /// <param name="interval">Time out in milliseconds between each process iteration.</param>
        /// <returns>All available connections.</returns>
        /// <autogeneratedoc />
        /// TODO Edit XML Comment Template for EnumerateConnections
        public static ConnectionSearchResult[] EnumerateConnections(
            ConnectionSearchTypes autoConnectorSearchTypes = ConnectionSearchTypes.All, int timeout = 500, int interval = 100)
        {
            using (SearchForConnections autoConnector2 = new SearchForConnections(autoConnectorSearchTypes, timeout, interval))
            {
                autoConnector2.Search();

                autoConnector2.Sort();

                return(autoConnector2.ToArray());
            }
        }