aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/TCC/Tango.TCC.CardDetector/CardDetectionConfig.cpp
blob: 12aed5597cff57ba415f328815868193106796bd (plain)
1
2
3
4
5
6
7
#include "CardDetectionConfig.h"

using namespace Tango::TCC::CardDetector;

CardDetectionConfig::CardDetectionConfig()
{
}
/* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using RealTimeGraphX.EventArguments;

namespace RealTimeGraphX
{
    /// <summary>
    /// Represents an <see cref="IGraphOutputComponent{TOut}"/> base class.
    /// </summary>
    /// <typeparam name="TOut">The type of the out.</typeparam>
    /// <seealso cref="RealTimeGraphX.GraphObject" />
    /// <seealso cref="RealTimeGraphX.IGraphOutputComponent{TOut}" />
    public abstract class GraphOutputComponentBase<TOut> : GraphObject, IGraphOutputComponent<TOut> where TOut : IGraphComponent
    {
        /// <summary>
        /// Occurs when the <see cref="P:RealTimeGraphX.IGraphOutputComponent`1.Output" /> property has changed.
        /// </summary>
        public event EventHandler<OutputChangedEventArgs<TOut>> OutputChanged;

        private TOut _output;
        /// <summary>
        /// Gets the connected output <see cref="T:RealTimeGraphX.IGraphComponent" />.
        /// </summary>
        public TOut Output
        {
            get { return _output; }
            set
            {
                _output = value;
                RaisePropertyChangedAuto();
                OnOutputChanged(_output);
            }
        }

        /// <summary>
        /// Raises the <see cref="OutputChanged"/> event.
        /// </summary>
        /// <param name="output">The output.</param>
        protected virtual void OnOutputChanged(TOut output)
        {
            OutputChanged?.Invoke(this, new OutputChangedEventArgs<TOut>(output));
        }

        /// <summary>
        /// Connects this component to another <see cref="T:RealTimeGraphX.IGraphComponent" />.
        /// </summary>
        /// <param name="output">The output component.</param>
        /// <param name="fromOutput">Specifies whether this call was made from a <see cref="TOut" /> component.</param>
        public abstract void ConnectOutput(TOut output, bool fromOutput = false);

        /// <summary>
        /// Disconnects this component from the connected <see cref="P:RealTimeGraphX.IGraphOutputComponent`1.Output" /><see cref="T:RealTimeGraphX.IGraphComponent" />.
        /// </summary>
        /// <param name="fromOutput">Specifies whether this call was made from a <see cref="TOut" /> component.</param>
        public abstract void DisconnectOutput(bool fromOutput = false);
    }
}