ILibraryAppletCreator.cs 796 B

123456789101112131415161718192021222324252627
  1. namespace Ryujinx.HLE.HOS.Services.Am
  2. {
  3. class ILibraryAppletCreator : IpcService
  4. {
  5. public ILibraryAppletCreator() { }
  6. [Command(0)]
  7. // CreateLibraryApplet(u32, u32) -> object<nn::am::service::ILibraryAppletAccessor>
  8. public ResultCode CreateLibraryApplet(ServiceCtx context)
  9. {
  10. MakeObject(context, new ILibraryAppletAccessor(context.Device.System));
  11. return ResultCode.Success;
  12. }
  13. [Command(10)]
  14. // CreateStorage(u64) -> object<nn::am::service::IStorage>
  15. public ResultCode CreateStorage(ServiceCtx context)
  16. {
  17. long size = context.RequestData.ReadInt64();
  18. MakeObject(context, new IStorage(new byte[size]));
  19. return ResultCode.Success;
  20. }
  21. }
  22. }