summaryrefslogtreecommitdiff
path: root/net
AgeCommit message (Collapse)AuthorFilesLines
2017-11-06Text files should not have executable bit set (#4480)Sergey Avseyev1-0/+0
2017-08-24Trimmed vtables of trailing zeroes.Wouter van Oortmerssen1-3/+7
This is something the format supports, but none of the builders were doing. Can save 10-20% on FlatBuffer binary size! Also fixed the Go tests. Change-Id: I616c56ce9bbcfcaee23aa24f0532fcb60b6a8c75 Tested: on Linux.
2016-09-19Added IFlatbufferObject.cs file to project for .net.FTT\kimsin1-0/+1
Before edition, IFlatbufferObject.cs file wasn't in the project and building the project throwed error.
2016-09-12Allow access to underlying ByteBufferAlberto Fernández1-0/+2
2016-08-31Switched C# accessors from classes to structsWouter van Oortmerssen5-29/+55
2016-08-26Merge pull request #3978 from TGIshib/keyWouter van Oortmerssen2-1/+57
Find by key on C# and Java (2)
2016-08-26Fix lookupByKey, improve compareStringsTGIshib1-11/+9
2016-08-24Merge pull request #2133 from evolutional/cs-bounds-checkWouter van Oortmerssen1-5/+17
C#: added #define BYTEBUFFER_NO_BOUNDS_CHECK
2016-08-22Improve `LookupByKey` , update docsTGIshib1-0/+22
2016-08-14UpdateTGIshib1-11/+31
2016-08-13Merge remote-tracking branch 'refs/remotes/google/master' into keyTGIshib1-0/+2
2016-08-10Clarified in the docs how to get to the serialized bytes.Wouter van Oortmerssen1-0/+2
This was a frequent source of confusion, since in all implementations the data doesn't start at offset 0 in the buffer. Change-Id: I045966e65928e9acd9def84e215914ecb5510653
2016-08-03RemakeTGIshib2-7/+23
2016-05-23Removed BOM marker from some files.Wouter van Oortmerssen5-9/+9
Also removed some trailing whitespace. Change-Id: I40bf4f776ca4d467b7ee6f2c9a7500c13700f9d5
2016-04-08Remove unnecessary condition in AssertOffsetAndLength.Wojciech Jaszczak1-2/+1
Condition is already checked and covered in the following condition, the second one was excess. Signed-off-by: Wojciech Jaszczak <jaszczakw@gmail.com>
2016-01-20Implemented ForceDefaults option on C# FlatBufferBuilder.Oli Wilkinson1-13/+116
Tested on: Windows, Unit Tests
2016-01-19Revamping the FlatBuffers docs.Mark Klara1-11/+128
Adding an API reference for the supported languages. General docs cleanup, including a new `tutorial` section that supports all of the supported languages. Added samples for each supported language to mirror the new tutorial page. Cleaned up all the links by making them `@ref` style links, instead of referencing the names of the generated `.html` files. Removed all generated files that were unnecessarily committed. Also fixed the C# tests (two were failing due to a missing file). Bug: b/25801305 Tested: Tested all samples on Ubuntu, Mac, and Android. Docs were generated using doxygen and viewed on Chrome. Change-Id: I2acaba6e332a15ae2deff5f26a4a25da7bd2c954
2015-12-14C# added BYTEBUFFER_NO_BOUNDS_CHECK #defineOli Wilkinson1-5/+17
Removes the bounds checking on the ByteBuffer Get/Put operations. Can be dangerous when used with UNSAFE_BYTEBUFFER but results in increased performance. Use at your own risk!
2015-12-14Merge pull request #2090 from evolutional/cs-perf-stringWouter van Oortmerssen2-11/+15
C# - Performance optimizations
2015-12-12C# performance optimization to Pad/Prep methodsOli Wilkinson2-5/+10
2015-12-11Performance tweak to FlatBufferBuilder.CreateString method to remove the ↵Oli Wilkinson1-6/+5
unnecessary byte buffer allocation (See https://github.com/google/flatbuffers/issues/55#issuecomment-164031718 for stats)
2015-12-07Merge pull request #288 from mfcollins3/csharp-byte-bufferWouter van Oortmerssen1-0/+15
Add Get Bytes Method Generator for C#
2015-12-07Merge pull request #776 from belldon/bytebuffer_pos_fixWouter van Oortmerssen1-5/+0
Extend C# ByteBuffer Put method fix to unsafe methods
2015-12-07Extend C# ByteBuffer Put method fix to unsafe methodsbelldon1-5/+0
Fixes issue #243. Extends the initial C# ByteBuffer fix (e4c3bf3d2cec00522fd1a8edd8704413cdc1303b) to Put methods used when UNSAFE_BYTEBUFFER is defined.
2015-12-07Update C# FlatBufferBuilder to reuse vtable arraybelldon1-12/+27
This commit updates the FlatBufferBuilder class to reuse the vtable array instead of creating a new array with every StartObject() call.
2015-12-04Add Get Bytes Method Generator for C#Michael Collins1-0/+15
I updated idl_gen_general.cpp to add support for generating a Get Bytes method for a vector to the generated C# source code. Given a byte vector field named Foo, a method named GetFooBytes() will be generated in the C# source code that will return an ArraySegment<byte> value referencing the vector data in the underlying ByteBuffer. I added a method to Table.cs named __vector_as_arraysegment that is used by the code generated by the change to the C# generator. __vector_as_arraysegment will take the offset of the vector and will return the ArraySegment<byte> value corresponding to the bytes that store the vector data. I updated FlatBuffersExampleTests.cs to add tests to validate my implementation of Table.__vector_as_arraysegment. I added tests to demonstrate that the bytes for the monster's name can be extracted from the underlying byte array. I also added tests to show that Table.__vector_as_arraysegment returns a null value if the vector is not present in the FlatBuffer. I used the updated flatc.exe program to regenerate the C# source files for the MyGame example. The new Monster class includes the GetXXXBytes methods to return the byte arrays containing data for vectors.
2015-11-10(C#) Add ByteBuffer property to TableShuhei Taunma1-0/+2
2015-08-07rebased forkMaor Itzkovitch4-5/+70
2015-08-07removed console print from codeMaor Itzkovitch1-1/+0
2015-08-07fixed C# bytebuffer put methodsMaor Itzkovitch2-9/+12
2015-08-01extended scalar mutator supportMaor Itzkovitch1-0/+6
2015-07-29Base type safety in C#. Clear FlatBufferBuilder in C#.RevenantX4-5/+70
2015-05-08Union accessors in C# should use generic type for the tableMormegil1-1/+1
When accessing a union field, we should return the same object type as was given to the method, i.e. the parameter should have a generic type for any Table-derived type. This way, we do not need to make superfluous casts (which also reduce type safety) like var myUnionType = (MyUnionType)buff.GetUnionField(new MyUnionType()); when we can do just var myUnionType = buff.GetUnionField(new MyUnionType()); Change-Id: Idac1b638e46cc50b1f2dc19f10741481202b1515
2015-05-06[BREAKING CHANGE] Field accessors should use property getters in C#Mormegil3-17/+16
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
2015-03-13Changed C# ByteBuffer to use bit shifts instead of BitConverterWouter van Oortmerssen1-42/+63
BitConverter was excessively slow since it allocates a byte array at each access. Bug: 18702381 Change-Id: I47be9c38e1d04287ba4c10bc369848f3e13a2a2f Tested: on Windows.
2015-03-13Regenerated test code + fixed typo in C# FlatBufferBuilderWouter van Oortmerssen1-2/+2
Change-Id: Ifa6d9459c53ae60b9bf936d9468ec971ee282f14 Tested: on Linux and Windows.
2015-03-11Added Copyright headersloverszhaokai2-3/+35
Change-Id: I106de8985cea572590d49c896b72c54f33e73bd2
2015-02-23Fixed C# Table.cs to work with Mono.Grégoire Astruc1-1/+1
Cast to short for mono compatibility. Change-Id: I568059a21369b895fa52002fa231f7594f0f736c
2015-01-26Support for booleans in the Java/C# APIWouter van Oortmerssen1-0/+7
Change-Id: I72e92183a7b5f4145ea51fcec29257dc9553a461
2015-01-16Fixed C# SizedByteArray copying leading bytes of ByteBuffer.Wouter van Oortmerssen2-5/+2
Tested: on Windows. Change-Id: I946dacf799eae835ec041ea759622f74b0384937
2015-01-06C#: Allow ByteBuffer to use faster unsafe modeJon Simantov1-2/+213
If your C# runtime environment supports unsafe mode, you can use the #define UNSAFE_BYTEBUFFER setting and build the FlatBuffers assembly in unsafe mode for greatly increased performance. Tested: Tested FlatBuffersTest on Windows using VS2010 with both safe and unsafe versions. Added ByteBufferTest to test the byte reversing functions. Change-Id: I21334468b339334f9abf4317e6291b648b97f57b
2014-09-22Support for required fields.Wouter van Oortmerssen1-0/+13
Change-Id: I560c7ca11b3d665eecafb528f3737b7e139ca9b0 Tested: on Linux and Windows.
2014-09-18Refactored the Java and C# code generators into one.Wouter van Oortmerssen4-37/+107
Also made the C# implementation support unsigned types, and made it more like the Java version. Bug: 17359988 Change-Id: If5305c08cd5c97f35426639516ce05e53bbec36c Tested: on Linux and Windows.
2014-09-15Initial commit of .NET port of FlatBuffersevolutional8-0/+727
Include C# codegen in flatc and .NET FlatBuffer access via the FlatBufferBuilder class Tested: on Windows. Change-Id: If5228a8df60a10e0751b245c6c64530264ea2d8a