Ejemplo n.º 1
0
 /// <summary>
 /// Return true if two computers have the same address on the network.
 /// </summary>
 /// <param name="other"></param>
 /// <returns></returns>
 public bool equals(DeploymentComputer other)
 {
     if (other == null)
     {
         return(false);
     }
     return(this.Name == other.Name ||
            (this.IsLocalHost && other.IsLocalHost));
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Constructor. Initializes members. This constructor sets the flag which indicates if this is the command
 /// to copy the dataprep folder to false.
 /// </summary>
 /// <exception cref="ArgumentException">Thrown if the command line is empty or null</exception>
 /// <param name="sCommand">The command line to be executed.</param>
 /// <param name="sWorkingDirectory">The working directory for the command to be executed.</param>
 /// <param name="sDescription">Command's description</param>
 public DeploymentCommand(DeploymentComputer SourceMachine, DataPrepPathZip sSourcePath, DataPrepPathZip sTargetPath, bool bFile, string sDescription)
 {
     // Set members
     this.SourceMachine = SourceMachine;
     this.sSourcePath   = sSourcePath;
     this.sTargetPath   = sTargetPath;
     this.bCopyFile     = bFile;
     this.sDescription  = sDescription;
     this.Type          = TypeCmd.DeployCmd;
 }
Ejemplo n.º 3
0
        /// <summary>
        /// Adds a command to the list of commands to deploy one or several files
        /// to this computer
        /// </summary>
        /// <param name="sDataPrepPath">The path where the data prep will be copied to</param>
        /// <exception cref="ArgumentException">Thrown if the output dataprep path is empty or null</exception>
        public void addDeployCommand(DeploymentComputer sourceMachine, string sourcePath, string sourceDest, bool bFile, string description)
        {
            DataPrepPathZip sourceInfo = new DataPrepPathZip();

            sourceInfo.Path = sourcePath;

            DataPrepPathZip destInfo = new DataPrepPathZip();

            destInfo.Path = sourceDest;


            // Add deploy command to list
            DeploymentCommand command = new DeploymentCommand(sourceMachine, sourceInfo, destInfo, bFile, description);

            this.lstCommands.Add(command);
        }