// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.

import "unknwn.idl";

typedef struct _CONSOLE_PORTABLE_ATTACH_MSG
{
    DWORD IdLowPart;
    LONG IdHighPart;
    ULONG64 Process;
    ULONG64 Object;
    ULONG Function;
    ULONG InputSize;
    ULONG OutputSize;
} CONSOLE_PORTABLE_ATTACH_MSG;

typedef CONSOLE_PORTABLE_ATTACH_MSG* PCONSOLE_PORTABLE_ATTACH_MSG;
typedef const CONSOLE_PORTABLE_ATTACH_MSG* PCCONSOLE_PORTABLE_ATTACH_MSG;

[
    object,
    uuid(E686C757-9A35-4A1C-B3CE-0BCC8B5C69F4)
] interface IConsoleHandoff : IUnknown
{
    HRESULT EstablishHandoff([in, system_handle(sh_file)] HANDLE server,
                             [in, system_handle(sh_event)] HANDLE inputEvent,
                             [in, ref] PCCONSOLE_PORTABLE_ATTACH_MSG msg,
                             [in, system_handle(sh_pipe)] HANDLE signalPipe,
                             [in, system_handle(sh_process)] HANDLE inboxProcess,
                             [out, system_handle(sh_process)] HANDLE* process);
};

[
    object,
    uuid(746E6BC0-AB05-4E38-AB14-71E86763141F)
] interface IDefaultTerminalMarker : IUnknown
{
};
