Skip to content

Commit 17fc5e1

Browse files
authored
Merge pull request #89 from objectbox/dev
v0.6.1 release
2 parents b733f30 + d0faa22 commit 17fc5e1

File tree

12 files changed

+29
-22
lines changed

12 files changed

+29
-22
lines changed

CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
0.6.1 (2020-01-23)
2+
------------------
3+
* Fix Flutter Android/iOS release build failures
4+
* Updated to objectbox-c 0.8.2
5+
16
0.6.0 (2019-12-19)
27
------------------
38
* Flutter iOS support

README.md

+2-3
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,16 @@ Installation
1616
Add the following dependencies to your `pubspec.yaml`:
1717
```yaml
1818
dependencies:
19-
objectbox: ^0.6.0
19+
objectbox: ^0.6.1
2020

2121
dev_dependencies:
2222
build_runner: ^1.0.0
23-
objectbox_generator: ^0.6.0
23+
objectbox_generator: ^0.6.1
2424
```
2525
2626
Proceed based on whether you're developing a Flutter app or a standalone dart program:
2727
1. **Flutter** only steps:
2828
* Install the packages `flutter pub get`
29-
* Note: only debug versions (e.g. `flutter run`) work at the moment, `flutter build` currently fails for release builds
3029
1. **Dart standalone programs**:
3130
* Install the packages `pub get`
3231
* Install [objectbox-c](https://github.com/objectbox/objectbox-c) system-wide:

android/build.gradle

+1
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ android {
44
}
55

66
dependencies {
7+
// https://github.com/objectbox/objectbox-java/releases
78
implementation "io.objectbox:objectbox-android:2.5.0"
89
}

example/flutter/objectbox_demo/pubspec.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,18 @@ dependencies:
1111
cupertino_icons: ^0.1.2
1212
path_provider: any
1313
intl: any
14-
objectbox: ^0.6.0
14+
objectbox: ^0.6.1
1515

1616
dev_dependencies:
1717
flutter_test:
1818
sdk: flutter
1919
build_runner: ^1.0.0
20-
objectbox_generator: ^0.6.0
20+
objectbox_generator: ^0.6.1
2121

2222
flutter:
2323
uses-material-design: true
2424

25-
# ---------------------------------
25+
# Note: these overrides are only for ObjectBox internal development, don't use them in your app.
2626
dependency_overrides:
2727
objectbox:
2828
path: ../../..

example/flutter/objectbox_demo_desktop/pubspec.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ dependencies:
1111
flutter:
1212
sdk: flutter
1313
cupertino_icons: ^0.1.0
14-
objectbox: ^0.6.0
14+
objectbox: ^0.6.1
1515

1616
dev_dependencies:
1717
flutter_test:
1818
sdk: flutter
1919
build_runner: ^1.0.0
20-
objectbox_generator: ^0.6.0
20+
objectbox_generator: ^0.6.1
2121

2222
flutter:
2323
uses-material-design: true
@@ -40,7 +40,7 @@ flutter:
4040
weight: 900
4141

4242

43-
# ---------------------------------
43+
# Note: these overrides are only for ObjectBox internal development, don't use them in your app.
4444
dependency_overrides:
4545
objectbox:
4646
path: ../../..

generator/pubspec.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: objectbox_generator
2-
version: 0.6.0
2+
version: 0.6.1
33
repository: https://github.com/objectbox/objectbox-dart
44
homepage: https://objectbox.io
55
description: ObjectBox binding code generator - finds annotated entities and adds them to the ObjectBox DB model.
@@ -8,7 +8,7 @@ environment:
88
sdk: ">=2.5.0 <3.0.0"
99

1010
dependencies:
11-
objectbox: 0.6.0
11+
objectbox: 0.6.1
1212
build: ^1.0.0
1313
source_gen: ^0.9.0
1414
analyzer: ">=0.35.0 <0.100.0"

install.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
#!/usr/bin/env bash
22
set -eu
33

4-
cLibVersion=0.8.1
4+
# https://github.com/objectbox/objectbox-c/releases
5+
cLibVersion=0.8.2
56
os=$(uname)
67

78
# if there's no tty this is probably part of a docker build - therefore we install the c-api explicitly

ios/download-framework.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
#!/usr/bin/env bash
22
set -euo pipefail
33

4-
# NOTE: run before publishing
4+
# NOTE: run this script before publishing
55

6+
# https://github.com/objectbox/objectbox-swift/releases/
67
obxSwiftVersion="1.2.0"
78

89
dir=$(dirname "$0")

lib/src/bindings/structs.dart

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class OBX_id_array extends Struct {
3232
array.length = items.length;
3333
array._itemsPtr = allocate<Uint64>(count: array.length);
3434
for (int i = 0; i < items.length; ++i) {
35-
array._itemsPtr.elementAt(i).value = items[i];
35+
array._itemsPtr[i] = items[i];
3636
}
3737

3838
// call the function with the structure and free afterwards
@@ -83,7 +83,7 @@ class OBX_bytes extends Struct {
8383
// create a copy of the data
8484
bytes._dataPtr = allocate<Uint8>(count: bytes.length);
8585
for (int i = 0; i < data.length; ++i) {
86-
bytes._dataPtr.elementAt(i).value = data[i];
86+
bytes._dataPtr[i] = data[i];
8787
}
8888

8989
return ptr;

lib/src/box.dart

+1-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ class Box<T> {
109109
Pointer<Uint64> allIdsMemory = allocate<Uint64>(count: objects.length);
110110
try {
111111
for (int i = 0; i < allPropVals.length; ++i) {
112-
allIdsMemory.elementAt(i).value = (allPropVals[i][_modelEntity.idProperty.name] as int);
112+
allIdsMemory[i] = (allPropVals[i][_modelEntity.idProperty.name] as int);
113113
}
114114

115115
// marshal all objects to be put into the box

lib/src/query/query.dart

+5-5
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ class StringCondition extends PropertyCondition<String> {
307307
final arrayOfCStrings = allocate<Pointer<Utf8>>(count: listLength);
308308
try {
309309
for (int i = 0; i < _list.length; i++) {
310-
arrayOfCStrings.elementAt(i).value = Utf8.toUtf8(_list[i]);
310+
arrayOfCStrings[i] = Utf8.toUtf8(_list[i]);
311311
}
312312
return func(builder._cBuilder, _property._propertyId, arrayOfCStrings, listLength, _caseSensitive ? 1 : 0);
313313
} finally {
@@ -373,7 +373,7 @@ class IntegerCondition extends PropertyCondition<int> {
373373
final listPtr = allocate<P>(count: length);
374374
try {
375375
for (int i=0; i<length; i++) {
376-
listPtr.elementAt(i).value = _list[i] as int; // Error: Expected type 'P' to be a valid and instantiated subtype of 'NativeType'. // wtf? Compiler bug?
376+
listPtr[i] = _list[i] as int; // Error: Expected type 'P' to be a valid and instantiated subtype of 'NativeType'. // wtf? Compiler bug?
377377
}
378378
return func(builder._cBuilder, _property.propertyId, listPtr, length);
379379
}finally {
@@ -388,7 +388,7 @@ class IntegerCondition extends PropertyCondition<int> {
388388
final listPtr = allocate<Int32>(count: length);
389389
try {
390390
for (int i = 0; i < length; i++) {
391-
listPtr.elementAt(i).value = _list[i];
391+
listPtr[i] = _list[i];
392392
}
393393
return func(builder._cBuilder, _property._propertyId, listPtr, length);
394394
} finally {
@@ -402,7 +402,7 @@ class IntegerCondition extends PropertyCondition<int> {
402402
final listPtr = allocate<Int64>(count: length);
403403
try {
404404
for (int i = 0; i < length; i++) {
405-
listPtr.elementAt(i).value = _list[i];
405+
listPtr[i] = _list[i];
406406
}
407407
return func(builder._cBuilder, _property._propertyId, listPtr, length);
408408
} finally {
@@ -506,7 +506,7 @@ class ConditionGroup extends Condition {
506506
throw Exception("Failed to create condition " + _conditions[i].toString());
507507
}
508508

509-
intArrayPtr.elementAt(i).value = cid;
509+
intArrayPtr[i] = cid;
510510
}
511511

512512
// root All (AND) is implicit so no need to actually combine the conditions

pubspec.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: objectbox
2-
version: 0.6.0
2+
version: 0.6.1
33
repository: https://github.com/objectbox/objectbox-dart
44
homepage: https://objectbox.io
55
description: ObjectBox is a super-fast NoSQL ACID compliant object database.

0 commit comments

Comments
 (0)