/// <summary>
        /// Get all manufacturers.
        /// </summary>
        /// <returns>The requested list filled with information.</returns>
        public List <Manufacturer> GetAll()
        {
            string              sql = string.Empty;
            Manufacturer        manufacturer;
            List <Manufacturer> manufacturers = new List <Manufacturer>();

            try
            {
                Connect();

                sql = @"SELECT 
                        " + ManufacturerDAO.SQL_FIELDS_SELECT + @"
                    FROM 
                        " + ManufacturerDAO.SQL_TABLE + @" 
                    ORDER BY 
                        buildname";

                using (SQLiteDataReader reader = ExecuteReader(sql))
                {
                    while (reader.Read())
                    {
                        manufacturer = ManufacturerDAO.ReadEntityRecord(reader);
                        if (manufacturer != null)
                        {
                            manufacturers.Add(manufacturer);
                        }
                    }
                }

                return(manufacturers);
            }
            catch (Exception ex)
            {
                Logger.LogError(this, ex);

                throw;
            }
            finally
            {
                Disconnect();
            }
        }
        /// <summary>
        /// Averigua el ID de un fabricante a partir de su nombre.
        /// </summary>
        /// <param name="name">Nombre del fabricante.</param>
        /// <returns>Identificador del registro.</returns>
        public Manufacturer GetByName(string name)
        {
            string sql = string.Empty;

            try
            {
                Connect();

                sql = @"SELECT 
                        " + ManufacturerDAO.SQL_FIELDS_SELECT + @" 
                  FROM 
                        " + ManufacturerDAO.SQL_TABLE + @" 
                  WHERE 
                        LCase(buildname) = @buildname";

                SetParameter("buildname", name);

                using (SQLiteDataReader reader = ExecuteReader(sql))
                {
                    if (reader.Read())
                    {
                        return(ManufacturerDAO.ReadEntityRecord(reader));
                    }
                }

                return(null);
            }
            catch (Exception ex)
            {
                Logger.LogError(this, ex);

                throw;
            }
            finally
            {
                Disconnect();
            }
        }