CodeContainerStorageManager.AddOrUpdateAsync 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
为提供的添加或更新 Shell 记录 codeContainer 。
还将漫游关联的( Remote 如果有)。
public System.Threading.Tasks.Task<int> AddOrUpdateAsync (Microsoft.VisualStudio.Shell.CodeContainerManagement.CodeContainer codeContainer, System.Threading.CancellationToken cancellationToken = default);
abstract member AddOrUpdateAsync : Microsoft.VisualStudio.Shell.CodeContainerManagement.CodeContainer * System.Threading.CancellationToken -> System.Threading.Tasks.Task<int>
override this.AddOrUpdateAsync : Microsoft.VisualStudio.Shell.CodeContainerManagement.CodeContainer * System.Threading.CancellationToken -> System.Threading.Tasks.Task<int>
Public Function AddOrUpdateAsync (codeContainer As CodeContainer, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Integer)
参数
- codeContainer
- CodeContainer
要添加或更新的容器
- cancellationToken
- CancellationToken
取消令牌
返回
分配给此更改的修订号
实现
例外
如果为 null,则引发 codeContainer 。