// Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using Microsoft.CodeAnalysis.Host;
using System.Threading;
namespace Microsoft.CodeAnalysis.Navigation
{
internal interface ISymbolNavigationService : IWorkspaceService
{
///
/// Navigate to the first source location of a given symbol.
///
/// A project context with which to generate source for symbol
/// if it has no source locations
/// The symbol to navigate to
/// Indicates whether a preview tab should be used if the
/// containing document is opened in a new tab. Defaults to false.
bool TryNavigateToSymbol(ISymbol symbol, Project project, CancellationToken cancellationToken, bool usePreviewTab = false);
/// True if the navigation was handled, indicating that the caller should not
/// perform the navigation.
bool TrySymbolNavigationNotify(ISymbol symbol, Solution solution);
/// True if the navigation would be handled.
bool WouldNavigateToSymbol(ISymbol symbol, Solution solution, out string filePath, out int lineNumber, out int charOffset);
}
}