//
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
//
using Microsoft.SqlTools.Hosting.Contracts;
namespace Microsoft.SqlTools.DataProtocol.Contracts.Connection
{
///
/// Parameters to be sent back with a connection complete event
///
public class ConnectionCompleteParams
{
///
/// A URI identifying the owner of the connection. This will most commonly be a file in the workspace
/// or a virtual file representing an object in a database.
///
public string OwnerUri { get; set; }
///
/// A GUID representing a unique connection ID
///
public string ConnectionId { get; set; }
///
/// Gets or sets any detailed connection error messages.
///
public string Messages { get; set; }
///
/// Error message returned from the engine for a connection failure reason, if any.
///
public string ErrorMessage { get; set; }
///
/// Error number returned from the engine for connection failure reason, if any.
///
public int ErrorNumber { get; set; }
///
/// Information about the connected server.
///
public ServerInfo ServerInfo { get; set; }
///
/// Gets or sets the actual Connection established, including Database Name
///
public ConnectionSummary ConnectionSummary { get; set; }
///
/// The type of connection that this notification is for
///
public string Type { get; set; } = ConnectionType.Default;
}
///
/// ConnectionComplete notification mapping entry
///
public class ConnectionCompleteNotification
{
public static readonly
EventType Type =
EventType.Create("connection/complete");
}
}