using System; namespace ETModel { public interface IMessagePacker { byte[] SerializeToByteArray(object obj); string SerializeToText(object obj); object DeserializeFrom(Type type, byte[] bytes); object DeserializeFrom(Type type, byte[] bytes, int index, int count); T DeserializeFrom(byte[] bytes); T DeserializeFrom(byte[] bytes, int index, int count); T DeserializeFrom(string str); object DeserializeFrom(Type type, string str); } }