public MountPoints(DockerContainer container) : base("_Mountpoint", new MountPointInstantiator()) { this.container = container; this.device = container.Device; api = TorizonAPIManager.GetDevicesApi(); }
public MemInfo(DockerContainer container) { this.container = container; this.device = container.Device; api = TorizonAPIManager.GetDevicesApi(); }
public Processes(DockerContainer container) : base("Pid", new ProcessInstantiator()) { this.container = container; this.device = container.Device; api = TorizonAPIManager.GetDevicesApi(); }
public async Task <DockerContainer> GetContainerAsync(string configuration, TargetDevice targetdevice, Action <DockerContainer> ContainerUpdated) { TorizonRestAPI.Model.DockerContainer model = Utils.ObjectOrException <TorizonRestAPI.Model.DockerContainer>(await api.ApplicationGetcontainerAsync(this.Id, configuration, targetdevice.Id)); DockerContainer container = new DockerContainer(model, targetdevice); ContainerUpdated?.Invoke(container); return(container); }
public DockerContainer GetSDKContainer(string configuration) { TorizonRestAPI.Model.DockerContainer model = Utils.ObjectOrException <TorizonRestAPI.Model.DockerContainer>( api.ApplicationSdkContainer(this.Id, configuration) ); DockerContainer container = new DockerContainer(model, null); return(container); }
public async Task <DockerContainer> RunAsync(string configuration, TargetDevice targetdevice, Action <string, int> runningAction, Action <DockerContainer> ApplicationStarted) { Progress progress = null; DockerContainer container = null; var taskBuild = CreateProgressTask(ref progress, runningAction); _ = api.ApplicationRunAsync(this.Id, configuration, targetdevice.Id, progress?.Id).ContinueWith(task => { TorizonRestAPI.Model.DockerContainer model = Utils.ObjectOrException <TorizonRestAPI.Model.DockerContainer>(task.Result); container = new DockerContainer(model, targetdevice); ApplicationStarted?.Invoke(container); }); await Task.Run(taskBuild); return(container); }