[BREAKING CHANGE] Field accessors should use property getters in C#
In C#, plain field accessors should not be nonparametric methods but should be standard property getters. The accessor methods with parameters were renamed to `GetXxx` because a method cannot be named identically to a property. Also, `ByteBuffer.Position`, `FlatBufferBuilder.Offset` and `FlatBufferBuilder.DataBuffer` are now properties instead of nonparametric accessor methods, for more idiomatic C# style. This is a breaking change, all client C# code accessing these fields needs to be changed (i.e. remove those `()` or add the `Get` prefix). Issue: #77 Change-Id: Iaabe9ada076e5ea2c69911cf6170fdda2df3487e
Showing
- docs/source/JavaUsage.md 23 additions, 3 deletionsdocs/source/JavaUsage.md
- net/FlatBuffers/ByteBuffer.cs 1 addition, 2 deletionsnet/FlatBuffers/ByteBuffer.cs
- net/FlatBuffers/FlatBufferBuilder.cs 14 additions, 14 deletionsnet/FlatBuffers/FlatBufferBuilder.cs
- net/FlatBuffers/Table.cs 1 addition, 1 deletionnet/FlatBuffers/Table.cs
- src/idl_gen_general.cpp 70 additions, 17 deletionssrc/idl_gen_general.cpp
- tests/FlatBuffers.Test/FlatBuffersExampleTests.cs 28 additions, 28 deletionstests/FlatBuffers.Test/FlatBuffersExampleTests.cs
- tests/MyGame/Example/Monster.cs 34 additions, 34 deletionstests/MyGame/Example/Monster.cs
- tests/MyGame/Example/Stat.cs 4 additions, 4 deletionstests/MyGame/Example/Stat.cs
- tests/MyGame/Example/Test.cs 3 additions, 3 deletionstests/MyGame/Example/Test.cs
- tests/MyGame/Example/Vec3.cs 8 additions, 8 deletionstests/MyGame/Example/Vec3.cs
Loading
Please register or sign in to comment