using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml.Linq;
using MySql.Data.MySqlClient;
namespace Bortnikov
{
    internal class DB
    {
        MySqlConnection connection = new MySqlConnection("server=192.168.201.207; port=3306; username=pozorisp; password=pozorisp; database=pozorisp_Bortnikov");

        public void openConnection()
        {
           if ( connection.State == System.Data.ConnectionState.Closed);
            connection.Open();
        }

        public void closeConnection()
        {
            if (connection.State == System.Data.ConnectionState.Open);
            connection.Close();
        }

        public MySqlConnection GetConnection()
        {
            return connection;
        }

      
    }

}
