-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ca3e2c6
commit 4e5b87c
Showing
9 changed files
with
1,952 additions
and
857 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
import 'package:isar/isar.dart'; | ||
|
||
part 'starmap.g.dart'; | ||
|
||
@collection | ||
class User { | ||
Id? id; | ||
late String name; | ||
|
||
@Backlink(to: 'user') | ||
final stars = IsarLinks<Star>(); | ||
} | ||
|
||
@collection | ||
class File { | ||
Id? id; | ||
|
||
@IndexType.hash | ||
late String filename; | ||
|
||
@Backlink(to: 'file') | ||
final stars = IsarLinks<Star>(); | ||
} | ||
|
||
@collection | ||
class Star { | ||
Id? id; | ||
|
||
late String name; | ||
late List<byte> data; | ||
final file = IsarLink<File>(); | ||
final user = IsarLink<User>(); | ||
|
||
final next = IsarLinks<Star>(); | ||
|
||
@Backlink(to: 'next') | ||
final prev = IsarLinks<Star>(); | ||
} |
Oops, something went wrong.