public void CanEncodeDecodeOutpoint() { var outPoint = new OutPoint(new Transaction().GetHash(), 0); string encoded = outPoint.ToHex(); var decoded = new OutPoint(); decoded.FromHex(encoded); Assert.Equal(outPoint, decoded); }
/// <inheritdoc /> public override void WriteJson(JsonWriter writer, OutPoint?value, JsonSerializer serializer) { string opHex = value?.ToHex() ?? throw new ArgumentNullException(nameof(value)); writer.WriteValue(opHex); }