* Clone struct (deep clone) * @this {!Balance} * @returns {!Balance} Cloned struct
()
| 2064 | * @returns {!Balance} Cloned struct |
| 2065 | */ |
| 2066 | clone () { |
| 2067 | // Serialize the struct to the FBE stream |
| 2068 | let writer = new BalanceModel(new fbe.WriteBuffer()) |
| 2069 | writer.serialize(this) |
| 2070 | |
| 2071 | // Deserialize the struct from the FBE stream |
| 2072 | let reader = new BalanceModel(new fbe.ReadBuffer()) |
| 2073 | reader.attachBuffer(writer.buffer) |
| 2074 | return reader.deserialize().value |
| 2075 | } |
| 2076 | |
| 2077 | /** |
| 2078 | * Is this struct equal to other one? |
nothing calls this directly
no test coverage detected