Ejemplo n.º 1
0
 /// <summary>
 /// Copies New Object From DeSerialization
 /// </summary>
 /// <param name="msettings">Object to copy</param>
 private void CopyThis(TestAppSettings msettings)
 {
     this.logFile            = msettings.LogFile;
     this.maxLogLen          = msettings.MaxLogLength;
     this.period             = msettings.Period;
     this.txsocketStayOpen   = msettings.TxSocketStayOpen;
     this.historyLength      = msettings.HistoryLength;
     this.distributionPrefix = msettings.distributionPrefix;
     this.senderDefault      = msettings.SenderDefault;
     this.distStatusDefault  = msettings.DistStatusDefault;
     this.distTypeDefault    = msettings.DistTypeDefault;
     this.confDefault        = msettings.ConfDefault;
     this.tcpSend            = msettings.TCPSend;
     this.tcpRecv            = msettings.TCPRecv;
     this.udpSend            = msettings.UDPSend;
     this.udpRecv            = msettings.UDPRecv;
     this.tcpDestHost        = msettings.TCPDestHost;
     this.tcpDestPort        = msettings.TCPDestPort;
     this.tcpListenPort      = msettings.TCPListenPort;
     this.udpDestHost        = msettings.UDPDestHost;
     this.udpDestPort        = msettings.UDPDestPort;
     this.udpListenPort      = msettings.UDPListenPort;
     this.fileSend           = msettings.FileSend;
     this.fileRecv           = msettings.FileRecv;
     this.sendFileName       = msettings.SendFileName;
     this.recvFileName       = msettings.RecvFileName;
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the MessageManager class
 /// Constructor That Will Take Pointer To Settings Object
 /// </summary>
 /// <param name="msettings">Pointer to Settings Object</param>
 public MessageManager(TestAppSettings msettings)
 {
     this.settings    = msettings;
     this.sendQ       = new BlockingQueue <EDXLDE>();
     this.recvQ       = new BlockingQueue <NameObject <string, EDXLDE> >();
     this.sendEnabled = true;
     this.recvEnabled = true;
     this.tcpReciever = new Receiver(this.settings.TCPListenPort);
     this.sendThr     = new Thread(new ThreadStart(this.SendQThr));
 }
Ejemplo n.º 3
0
        /// <summary>
        /// Initializes a new instance of the SettingsForm class
        /// Constructor That Takes Settings Object
        /// </summary>
        /// <param name="settings">Settings Objet</param>
        /// <param name="settingsFile">Path + Name of the Settings File</param>
        public SettingsForm(TestAppSettings settings, string settingsFile)
        {
            this.InitializeComponent();
            List <string> enumTemp = new List <string>(Enum.GetNames(typeof(StatusValue)));

            // Add Enum Values to ComboBoxes
            foreach (string s in enumTemp)
            {
                this.mComboDistStatusDefault.Items.Add(s);
            }

            enumTemp = new List <string>(Enum.GetNames(typeof(TypeValue)));
            foreach (string s in enumTemp)
            {
                this.mComboDistTypeDefault.Items.Add(s);
            }

            this.settingsTempPtr  = settings;
            this.settingsTemp     = new TestAppSettings(this.settingsTempPtr);
            this.settingsTempFile = settingsFile;
            this.InitializeFormValues();
        }