예제 #1
0
        private bool _stopAll;               //Flag for all uploads to be stopped

        ///
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="_strProName">Project's name the tab belongs to</param>
        /// <param name="_tabInterface">TabPageInterface Reference</param>
        public cTabPage(string strProName, TabPageInterface tabInterface)
        {
            _strProName   = strProName;
            _tabInterface = tabInterface;
            _lstStopList  = new List <string>();
            _stopAll      = false;
            InitializeComponent();
        }
예제 #2
0
        private System.Timers.Timer editBtnTimer  = new System.Timers.Timer(1000); //Used for enabling disabling the edit button

        ///
        /// <summary>
        /// Constructor.
        /// Starts the edit button checking timer.
        /// </summary>
        public Main()
        {
            checkWput();
            InitializeComponent();
            _proInter = new ProjectInterface(); //Creates Project Interface.  Passes its own reference
            _tabInter = new TabPageInterface(this);
            _proInter.addTabRef(_tabInter);
            _tabInter.addProRef(_proInter);
            editBtnCheck();
        }
예제 #3
0
        private List <string> lstStopped;                           //List of IPs that have been told to stop

        ///
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="ps">Project settings to be uploaded</param>
        /// <param name="tabInt">Reference to project's tab page</param>
        public UploadSession(ProjectSettings ps, TabPageInterface tabInt)
        {
            this.pSettings        = ps;
            this.killAll          = false;
            this.tabInt           = tabInt;
            this.dicActiveUploads = new Dictionary <string, TargetUpload>();
            this.lstCompleted     = new List <string>();
            this.lstThreads       = new List <Thread>();
            this.lstStopped       = new List <string>();
        }
예제 #4
0
        ///
        /// <summary>
        /// Constructor.
        /// </summary>
        /// <param name="proSettings">Project's settings</param>
        /// <param name="ts">Target's settings</param>
        /// <param name="tabInt">Reference to TabPage Interface</param>
        public TargetUpload(ProjectSettings proSettings, TargetSettings ts, TabPageInterface tabInt)
        {
            _proSettings = proSettings;
            _strProName  = proSettings.ProjectName;
            _tSettings   = ts;
            DirectoryInfo d = new DirectoryInfo(proSettings.SourcePath);

            _numDirectorySize = this.dirSize(d);                  //Finds size of the directory
            WputOutput       += new WputOutputHandler(tabInt.OnUpdateProgress);
            ProcessStop      += new ProcessStoppedHandler(tabInt.OnProcessStopEvent);
            ProcessError     += new ProcessErrorHandler(tabInt.OnProcessErrorEvent);
            _strTargetServer  = _tSettings.TargetServer;
        }
예제 #5
0
 ///
 /// <summary>
 /// Assigns Tab Page Interface reference
 /// </summary>
 /// <param name="_tabInterface"></param>
 public void addTabRef(TabPageInterface tabInterface)
 {
     _tabInterface = tabInterface;
 }
예제 #6
0
        private List <TargetSettings> _lstTargets; //List of all target IPs

        ///
        /// <summary>
        /// Constructor.
        /// Used for creating a new project.
        /// </summary>
        /// <param name="_proSettings"> The settings to be used by the project </param>
        public Project(ProjectSettings proSettings, TabPageInterface tabInt)
        {
            _proSettings   = proSettings;
            _lstTargets    = new List <TargetSettings>();
            _uploadSession = new UploadSession(proSettings, tabInt);
        }