Esempio n. 1
0
        public void addProcess(String name, String path, String args)
        {
            DataProcess process = new DataProcess();

            process.setName(name);
            process.setPath(path);
            process.setArgs(args);
            dataProcesses.Add(process);
            SaveData();
        }
Esempio n. 2
0
 public DataProcess findProcessByPath(String path)
 {
     for (int i = 0; i < dataProcesses.Count; i++)
     {
         DataProcess process = dataProcesses[i];
         if (process.getPath() == path)
         {
             return(process);
         }
     }
     return(null);
 }
Esempio n. 3
0
 public DataProcess findProcessByName(String name)
 {
     for (int i = 0; i < dataProcesses.Count; i++)
     {
         DataProcess process = dataProcesses[i];
         if (process.getName() == name)
         {
             return(process);
         }
     }
     return(null);
 }
Esempio n. 4
0
        public void deleteProcess(String s)
        {
            DataProcess process = findProcessByPath(s);

            if (process == null)
            {
                process = findProcessByName(s);
            }
            if (process != null)
            {
                dataProcesses.Remove(process);
            }
            SaveData();
        }