Added a default costructor for Java's FlatBufferBuilder.
Default's size of 1024b like in cpp. Fixes #190.
This commit is contained in:
parent
39833d7cf0
commit
9fa3e2f387
|
@ -52,6 +52,13 @@ public class FlatBufferBuilder {
|
|||
bb = newByteBuffer(initial_size);
|
||||
}
|
||||
|
||||
/**
|
||||
* Start with a buffer of 1KiB, then grow as required.
|
||||
*/
|
||||
public FlatBufferBuilder() {
|
||||
this(1024);
|
||||
}
|
||||
|
||||
/**
|
||||
* Alternative constructor allowing reuse of {@link ByteBuffer}s. The builder
|
||||
* can still grow the buffer as necessary. User classes should make sure
|
||||
|
|
Loading…
Reference in New Issue