* Clone struct (deep clone) * @this {!StructNested} * @returns {!StructNested} Cloned struct
()
| 11050 | * @returns {!StructNested} Cloned struct |
| 11051 | */ |
| 11052 | clone () { |
| 11053 | // Serialize the struct to the FBE stream |
| 11054 | let writer = new StructNestedModel(new fbe.WriteBuffer()) |
| 11055 | writer.serialize(this) |
| 11056 | |
| 11057 | // Deserialize the struct from the FBE stream |
| 11058 | let reader = new StructNestedModel(new fbe.ReadBuffer()) |
| 11059 | reader.attachBuffer(writer.buffer) |
| 11060 | return reader.deserialize().value |
| 11061 | } |
| 11062 | |
| 11063 | /** |
| 11064 | * Is this struct equal to other one? |
nothing calls this directly
no test coverage detected