private CommandValues.GenericInfoCommandValue PrintPoolInformation(QPool pool) { var info = new CommandValues.GenericInfoCommandValue(); info.Uuid = pool.Uuid.ToString(); info.Message = "New pool created, state : " + pool.State; return(info); }
private CommandValues.GenericInfoCommandValue PrintBucketInformation(QBucket bucket) { var info = new CommandValues.GenericInfoCommandValue(); info.Uuid = bucket.Shortname; info.Message = "New bucket created, "; return(info); }
private CommandValues.GenericInfoCommandValue PrintTaskInformation(QTask task) { var info = new CommandValues.GenericInfoCommandValue(); info.Uuid = task.Uuid.ToString(); info.Message = "New task created, state : " + task.State; return(info); }
private CommandValues.GenericInfoCommandValue PrintJobInformation(QJob job) { var info = new CommandValues.GenericInfoCommandValue(); info.Uuid = job.Uuid.ToString(); info.Message = "New job created, state : " + job.State; return(info); }
public virtual async Task <string> RunAndPrintCommandAsync(IConfiguration config, IPrinter printer, CancellationToken ct = default(CancellationToken)) { Connection connect = this.API.CreateConnection(config); CommandValues.GenericInfoCommandValue info = await this.Creator.Create(config, connect, ct); string returnString = FormatToString.Format(info); if (printer != null) { await printer.PrintAsync(returnString); } return(returnString); }