aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.Horizon/Sdk/Sf/Hipc/Server.cs
blob: bbbab89855da07600ab671fe5cb82c8c99d98534 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
using Ryujinx.Horizon.Sdk.OsTypes;
using Ryujinx.Horizon.Sdk.Sf.Cmif;
using Ryujinx.Horizon.Sdk.Sm;

namespace Ryujinx.Horizon.Sdk.Sf.Hipc
{
    class Server : MultiWaitHolderOfHandle
    {
        public int                 PortIndex    { get; }
        public int                 PortHandle   { get; }
        public ServiceName         Name         { get; }
        public bool                Managed      { get; }
        public ServiceObjectHolder StaticObject { get; }

        public Server(
            int                 portIndex,
            int                 portHandle,
            ServiceName         name,
            bool                managed,
            ServiceObjectHolder staticHoder) : base(portHandle)
        {
            PortHandle = portHandle;
            Name       = name;
            Managed    = managed;

            if (staticHoder != null)
            {
                StaticObject = staticHoder;
            }
            else
            {
                PortIndex = portIndex;
            }
        }
    }
}