public override Task <bool> FixAsync(ICodeCleanUpScope scope, ICodeCleanUpExecutionContext context, CancellationToken cancellationToken) { switch (scope) { case TextBufferCodeCleanUpScope textBufferScope: return(FixTextBufferAsync(textBufferScope, context, cancellationToken)); case IVsHierarchyCodeCleanupScope hierarchyContentScope: return(FixHierarchyContentAsync(hierarchyContentScope, context, cancellationToken)); default: return(Task.FromResult(false)); } }
public Task <bool> FixAsync(ICodeCleanUpScope scope, ICodeCleanUpExecutionContext context) => scope switch {
public abstract Task <bool> FixAsync(ICodeCleanUpScope scope, ICodeCleanUpExecutionContext context, CancellationToken cancellationToken);
public abstract Task <bool> FixAsync(ICodeCleanUpScope scope, ICodeCleanUpExecutionContext context);
public virtual Task <bool> FixAsync(ICodeCleanUpScope scope, ICodeCleanUpExecutionContext context, CancellationToken _) { // cancellation token will be removed in next API update return(FixAsync(scope, context)); }