如何在Flutter中查看Object Box数据库?

huangapple go评论64阅读模式
英文:

how can i see Object box database in flutter?

问题

我已经制作了一个Flutter应用程序,并在离线模式下使用ObjectBox数据库来存储数据。

但现在的问题是如何查看数据库中存储了哪些数据,有多少表格或条目?

我阅读了ObjectBox的文档,但像我这样刚入门的人需要一些指导或简单的步骤,来查看ObjectBox数据库。

ObjectBox包:https://pub.dev/packages/objectbox

英文:

I have made a flutter application and to store data in offline mode I use an object box database.

but now the issue is how can see what data are stored in a database. how many tables or entries are there?

i read documentation from the object box but like me who is fresher in it need some guidance or simple steps how can I see the object box database?

object box package : https://pub.dev/packages/objectbox

答案1

得分: 1

我相信您要找的是这个:

ObjectBox 管理员 Web 应用程序

您需要进行必要的设置,然后使用以下代码获取您的 ObjectBox 数据库的 Admin 实例:

if (Admin.isAvailable()) {
  // 在不再需要时或手动关闭之前保留引用。
  admin = Admin(store);
}

// (可选)稍后关闭。
admin.close();
英文:

I believe what you are looking for is this:

> ObjectBox Admin Web App

you will need to do the required setup for, then get an Admin instance for your ObjectBox database with:

if (Admin.isAvailable()) {
  // Keep a reference until no longer needed or manually closed.
  admin = Admin(store);
}

// (Optional) Close at some later point.
admin.close();

huangapple
  • 本文由 发表于 2023年3月9日 21:29:10
  • 转载请务必保留本文链接:https://go.coder-hub.com/75685269.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定