Exemplo n.º 1
0
 ///GENMHASH:FC4CCB4833EA2DD311741B384FD9316F:8E288AFF39988D3B6818D60EB161D26B
 internal RegistryTaskRunImpl(IRegistryManager registryManager, RunInner runInner)
 {
     this.registryManager = registryManager;
     this.registriesInner = registryManager.Inner.Registries;
     this.platform        = new PlatformProperties();
     this.inner           = runInner;
 }
Exemplo n.º 2
0
        ///GENMHASH:28267C95BE469468FC3C62D4CF4CCA7C:0C065EC515A62F7E683F51864F7D2D5F
        public async Task <Microsoft.Azure.Management.ContainerRegistry.Fluent.IRegistryTaskRun> ExecuteAsync(CancellationToken cancellationToken = default(CancellationToken))
        {
            if (this.fileTaskRunRequest != null)
            {
                RunInner runInner = await this.registriesInner.ScheduleRunAsync(this.resourceGroupName, this.registryName, this.fileTaskRunRequest, cancellationToken);

                this.inner = runInner;
                return(this);
            }
            else if (this.encodedTaskRunRequest != null)
            {
                RunInner runInner = await this.registriesInner.ScheduleRunAsync(this.resourceGroupName, this.registryName, this.encodedTaskRunRequest, cancellationToken);

                this.inner = runInner;
                return(this);
            }
            else if (this.dockerTaskRunRequest != null)
            {
                RunInner runInner = await this.registriesInner.ScheduleRunAsync(this.resourceGroupName, this.registryName, this.dockerTaskRunRequest, cancellationToken);

                this.inner = runInner;
                return(this);
            }
            else if (this.taskRunRequest != null)
            {
                RunInner runInner = await this.registriesInner.ScheduleRunAsync(this.resourceGroupName, this.registryName, this.taskRunRequest, cancellationToken);

                this.inner = runInner;
                return(this);
            }
            throw new InvalidOperationException("Unsupported file task run request");
        }
Exemplo n.º 3
0
        ///GENMHASH:5A2D79502EDA81E37A36694062AEDC65:2F5CBFE7B258DDFB93CC76AAD3FE8250
        public async Task <Microsoft.Azure.Management.ContainerRegistry.Fluent.IRegistryTaskRun> RefreshAsync(CancellationToken cancellationToken = default(CancellationToken))
        {
            RunInner runInner = await registryManager.Inner.Runs.GetAsync(this.resourceGroupName, this.registryName, this.inner.RunId, cancellationToken);

            this.inner = runInner;
            return(this);
        }
Exemplo n.º 4
0
 ///GENMHASH:E444E59EA6E339F222A60E48B613B03A:556B0668F654DBF4EB9E776753D9FBD5
 private RegistryTaskRunImpl WrapModel(RunInner innerModel)
 {
     return(new RegistryTaskRunImpl(registryManager, innerModel));
 }