forked from Mirror/Ryujinx
a0720b5681
* Refactoring HOS folder structure Refactoring HOS folder structure: - Added some subfolders when needed (Following structure decided in private). - Added some `Types` folders when needed. - Little cleanup here and there. - Add services placeholders for every HOS services (close #766 and #753). * Remove Types namespaces
30 lines
No EOL
802 B
C#
30 lines
No EOL
802 B
C#
using System.Collections.Generic;
|
|
using System.Linq;
|
|
|
|
namespace Ryujinx.HLE.HOS.Services.Nifm.StaticService.GeneralService
|
|
{
|
|
static class GeneralServiceManager
|
|
{
|
|
private static List<GeneralServiceDetail> _generalServices = new List<GeneralServiceDetail>();
|
|
|
|
public static int Count
|
|
{
|
|
get => _generalServices.Count;
|
|
}
|
|
|
|
public static void Add(GeneralServiceDetail generalServiceDetail)
|
|
{
|
|
_generalServices.Add(generalServiceDetail);
|
|
}
|
|
|
|
public static void Remove(int index)
|
|
{
|
|
_generalServices.RemoveAt(index);
|
|
}
|
|
|
|
public static GeneralServiceDetail Get(int clientId)
|
|
{
|
|
return _generalServices.First(item => item.ClientId == clientId);
|
|
}
|
|
}
|
|
} |