public TaskManager(RepeatClient client) { this.client = client; this.compiler = new CSCompiler("."); actions = new Dictionary <string, UserDefinedAction>(); emptyAction = new EmptyAction(""); }
public IHttpActionResult PutRepeatClient(int id, RepeatClient repeatClient) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (id != repeatClient.RepeatClientId) { return(BadRequest()); } db.Entry(repeatClient).State = EntityState.Modified; try { db.SaveChanges(); } catch (DbUpdateConcurrencyException) { if (!RepeatClientExists(id)) { return(NotFound()); } else { throw; } } return(StatusCode(HttpStatusCode.NoContent)); }
public ActionResult DeleteConfirmed(int id) { RepeatClient repeatClient = db.RepeatClients.Find(id); db.RepeatClients.Remove(repeatClient); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "id,value")] RepeatClient repeatClient) { if (ModelState.IsValid) { db.Entry(repeatClient).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(repeatClient)); }
public static void Main(String[] args) { SetConsoleCtrlHandler(new HandlerRoutine(ConsoleCtrlCheck), true); BasicConfigurator.Configure(); int port = GetPort(args); client = new RepeatClient(port); client.StartRunning(); logger.Info("Successfully started C# IPC client."); }
public ActionResult Create([Bind(Include = "id,value")] RepeatClient repeatClient) { if (ModelState.IsValid) { db.RepeatClients.Add(repeatClient); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(repeatClient)); }
public IHttpActionResult GetRepeatClient(int id) { RepeatClient repeatClient = db.RepeatClients.Find(id); if (repeatClient == null) { return(NotFound()); } return(Ok(repeatClient)); }
public IHttpActionResult PostRepeatClient(RepeatClient repeatClient) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } db.RepeatClients.Add(repeatClient); db.SaveChanges(); return(CreatedAtRoute("DefaultApi", new { id = repeatClient.RepeatClientId }, repeatClient)); }
// GET: RepeatClients/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } RepeatClient repeatClient = db.RepeatClients.Find(id); if (repeatClient == null) { return(HttpNotFound()); } return(View(repeatClient)); }
public IHttpActionResult DeleteRepeatClient(int id) { RepeatClient repeatClient = db.RepeatClients.Find(id); if (repeatClient == null) { return(NotFound()); } db.RepeatClients.Remove(repeatClient); db.SaveChanges(); return(Ok(repeatClient)); }
public MouseRequest(RepeatClient client) : base(client) { this.Type = "action"; this.Device = "mouse"; }
public KeyboardRequest(RepeatClient client) : base(client) { this.Type = "action"; this.Device = "keyboard"; }
public RequestGenerator(RepeatClient client) { this.client = client; ParamStrings = new List <string>(); ParamInt = new List <int>(); }
public SystemClientRequest(RepeatClient client) : base(client) { this.Type = "system_client"; this.Device = "system"; }
public ToolRequest(RepeatClient client) : base(client) { this.Type = "action"; this.Device = "tool"; }
public SharedMemoryRequest(RepeatClient client) : base(client) { this.Type = "shared_memory"; this.Device = "shared_memory"; }