Skip to content

Commit

Permalink
Updated ExampleClass
Browse files Browse the repository at this point in the history
  • Loading branch information
abledbody committed Oct 25, 2023
1 parent af9f079 commit cf38f69
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Assets/QuickBin/ExampleClass.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
using UnityEngine;
using QuickBin;

namespace Example {
namespace QuickBin.Example {
public class ExampleClass {
// All of these types are easily serialized in QuickBin.
public string name;
Expand Down Expand Up @@ -53,7 +52,7 @@ public ExampleClass Clone() {
var serializer = new Serializer().Write(this);

// Serializer can be implicitly cast to a byte array so you don't have to think about it.
// It's also what the constructor for Deserializer takes, so this becomes a dead simple operation.
// A byte array is also what the constructor for Deserializer takes, so this becomes a dead simple operation.
new Deserializer(serializer).Read(out ExampleClass produced);

return produced;
Expand Down

0 comments on commit cf38f69

Please sign in to comment.