using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Diagnostics;

namespace EMDServer.Core
{
    class DeviceConnection
    {
        #region Class variables
        // ----------------------------------------
        private int devId1;
        private int devId2;
        private bool connectionActive;
        // ----------------------------------------
        #endregion

        #region Public methods
        // ----------------------------------------
        /// <summary>
        /// Creates a new instance of the class
        /// </summary>
        public DeviceConnection()
        {
            //Debug.WriteLine("DEVICECONNECTION - Instantiated!");
        }

        /// <summary>
        /// Creates a new instance of the class
        /// </summary>
        /// <param name="id1">int id of Device 1</param>
        /// <param name="id2">int id of Device 2</param>
        public DeviceConnection(int devId1, int devId2)
        {
            this.devId1 = devId1;
            this.devId2 = devId2;

            this.connectionActive = false;

            //Debug.WriteLine("DEVICECONNECTION - Instantiated!");
        }

        /// <summary>
        /// Creates a new instance of the class
        /// </summary>
        /// <param name="id1">int id of Device 1</param>
        /// <param name="id2">int id of Device 2</param>
        /// <param name="active">bool value which indicates whether or not the connection is active</param>
        public DeviceConnection(int devId1, int devId2, bool active)
        {
            this.devId1 = devId1;
            this.devId2 = devId2;

            this.connectionActive = active;

            //Debug.WriteLine("DEVICECONNECTION - Instantiated!");
        }
        // ----------------------------------------
        #endregion

        #region Properties
        // ----------------------------------------
        /// <summary>
        /// Gets or sets the int input Device id
        /// </summary>
        public int DevId1
        {
            get { return devId1; }
            set { devId1 = value; }
        }

        /// <summary>
        /// Gets or sets the int output Device id
        /// </summary>
        public int DevId2
        {
            get { return devId2; }
            set { devId2 = value; }
        }

        /// <summary>
        /// Gets or sets the bool connection active
        /// </summary>
        public bool ConnectionActive
        {
            get { return connectionActive; }
            set { connectionActive = value; }
        }
        // ----------------------------------------
        #endregion
    }
}
