Skip to content

Commit 415220c

Browse files
committed
ModelProperty: add maxIndexValueLength
1 parent d2fadcd commit 415220c

File tree

1 file changed

+6
-17
lines changed

1 file changed

+6
-17
lines changed

objectbox-java/src/main/java/io/objectbox/model/ModelProperty.java

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,3 @@
1-
/*
2-
* Copyright 2017 ObjectBox Ltd. All rights reserved.
3-
*
4-
* Licensed under the Apache License, Version 2.0 (the "License");
5-
* you may not use this file except in compliance with the License.
6-
* You may obtain a copy of the License at
7-
*
8-
* http://www.apache.org/licenses/LICENSE-2.0
9-
*
10-
* Unless required by applicable law or agreed to in writing, software
11-
* distributed under the License is distributed on an "AS IS" BASIS,
12-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13-
* See the License for the specific language governing permissions and
14-
* limitations under the License.
15-
*/
16-
171
// automatically generated by the FlatBuffers compiler, do not modify
182

193
package io.objectbox.model;
@@ -60,8 +44,12 @@ public final class ModelProperty extends Table {
6044
public String nameSecondary() { int o = __offset(18); return o != 0 ? __string(o + bb_pos) : null; }
6145
public ByteBuffer nameSecondaryAsByteBuffer() { return __vector_as_bytebuffer(18, 1); }
6246
public ByteBuffer nameSecondaryInByteBuffer(ByteBuffer _bb) { return __vector_in_bytebuffer(_bb, 18, 1); }
47+
/**
48+
* For value-based indexes, this defines the maximum length of the value stored for indexing
49+
*/
50+
public long maxIndexValueLength() { int o = __offset(20); return o != 0 ? (long)bb.getInt(o + bb_pos) & 0xFFFFFFFFL : 0L; }
6351

64-
public static void startModelProperty(FlatBufferBuilder builder) { builder.startObject(8); }
52+
public static void startModelProperty(FlatBufferBuilder builder) { builder.startObject(9); }
6553
public static void addId(FlatBufferBuilder builder, int idOffset) { builder.addStruct(0, idOffset, 0); }
6654
public static void addName(FlatBufferBuilder builder, int nameOffset) { builder.addOffset(1, nameOffset, 0); }
6755
public static void addType(FlatBufferBuilder builder, int type) { builder.addShort(2, (short)type, (short)0); }
@@ -70,6 +58,7 @@ public final class ModelProperty extends Table {
7058
public static void addTargetEntity(FlatBufferBuilder builder, int targetEntityOffset) { builder.addOffset(5, targetEntityOffset, 0); }
7159
public static void addVirtualTarget(FlatBufferBuilder builder, int virtualTargetOffset) { builder.addOffset(6, virtualTargetOffset, 0); }
7260
public static void addNameSecondary(FlatBufferBuilder builder, int nameSecondaryOffset) { builder.addOffset(7, nameSecondaryOffset, 0); }
61+
public static void addMaxIndexValueLength(FlatBufferBuilder builder, long maxIndexValueLength) { builder.addInt(8, (int)maxIndexValueLength, (int)0L); }
7362
public static int endModelProperty(FlatBufferBuilder builder) {
7463
int o = builder.endObject();
7564
return o;

0 commit comments

Comments
 (0)