public override void SerializePatch(BinaryWriter writer) { SerializingUtils.SerializeMethodReference(Method, writer); writer.Write(Changes.Length); foreach (MethodChange change in Changes) { writer.Write((byte)change.Action); SerializingUtils.SerializeInstruction(change.Instruction, writer); writer.Write(change.Index); } }
public override Patch DeserializePatch(BinaryReader reader) { Method = SerializingUtils.DeserializeMethodReference(reader); Changes = new MethodChange[reader.ReadInt32()]; for (int i = 0; i < Changes.Length; i++) { Changes[i] = new MethodChange( (InstructionAction)reader.ReadByte(), SerializingUtils.DeserializeInstruction(reader), reader.ReadInt32()); } return(this); }
public override Patch DeserializePatch(BinaryReader reader) { ParentType = SerializingUtils.DeserializeTypeReference(reader); NestedType = SerializingUtils.DeserializeTypeDefinition(reader); return(this); }
public override void SerializePatch(BinaryWriter writer) { SerializingUtils.SerializeTypeReference(ParentType, writer); SerializingUtils.SerializeTypeDefinition(NestedType, writer); }