From 9e4462008ca5237759a16c2ce78f88db5b621bcd Mon Sep 17 00:00:00 2001 From: nattthebear Date: Sat, 20 May 2017 12:09:50 -0400 Subject: [PATCH] break IStateable down because I need just binary for some internal stuff... --- .../Interfaces/Services/IStatable.cs | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/BizHawk.Emulation.Common/Interfaces/Services/IStatable.cs b/BizHawk.Emulation.Common/Interfaces/Services/IStatable.cs index 4c375d67b0..b2580671c9 100644 --- a/BizHawk.Emulation.Common/Interfaces/Services/IStatable.cs +++ b/BizHawk.Emulation.Common/Interfaces/Services/IStatable.cs @@ -2,13 +2,22 @@ namespace BizHawk.Emulation.Common { + /// + /// Binary save and load state only without any trappings. At the moment, an emulator core should not implement this directly + /// + public interface IBinaryStateable + { + void SaveStateBinary(BinaryWriter writer); + void LoadStateBinary(BinaryReader reader); + } + /// /// This service manages the logic of sending and receiving savestates from the core /// If this service is available, client apps will expose features for making savestates and that utilize savestates (such as rewind)) /// If unavailable these options will not be exposed /// Additionally many tools depend on savestates such as TAStudio, these will only be available if this service is implemented /// - public interface IStatable : IEmulatorService + public interface IStatable : IBinaryStateable, IEmulatorService { /// /// Gets a value indicating whether the core would rather give a binary savestate than a text one. Both must function regardless @@ -18,9 +27,6 @@ namespace BizHawk.Emulation.Common void SaveStateText(TextWriter writer); void LoadStateText(TextReader reader); - void SaveStateBinary(BinaryWriter writer); - void LoadStateBinary(BinaryReader reader); - /// /// save state binary to a byte buffer ///