Closed. This question does not meet Stack Overflow guidelines。它当前不接受答案。
想改善这个问题吗? Update the question,所以它是on-topic,用于堆栈溢出。
5年前关闭。
您能否提出一些想法,如何将脱机圣经纳入基于电话缺口的应用程序中?将来可能需要章节和章节的书签。我将如何去做。本地json文件可能是?但是我找不到有意义的json。寻找圣经。也不确定如何使json方法可扩展以符合书签。有什么想法吗?
使用这种结构,任何经文都应该非常快速地进行查找:要拉这本书,这是一个哈希映射查找,然后Chapter和verse是数组偏移量。
想改善这个问题吗? Update the question,所以它是on-topic,用于堆栈溢出。
5年前关闭。
您能否提出一些想法,如何将脱机圣经纳入基于电话缺口的应用程序中?将来可能需要章节和章节的书签。我将如何去做。本地json文件可能是?但是我找不到有意义的json。寻找圣经。也不确定如何使json方法可扩展以符合书签。有什么想法吗?
最佳答案
全文仅为~4MB,这意味着在您的应用程序运行时将全文加载到内存中应该不是问题。然后,JSON应该适合做书签-由于圣经的结构方式,嵌套嵌套的哈希/数组查找很简单:
var bible = {
genesis: [
[ // first chapter
"In the beginning God created the heaven and the earth.",
"And the earth was without form, and void; and darkness was upon the face of the deep. And the Spirit of God moved upon the face of the waters.",
...
],
[ // second chapter
"Thus the heavens and the earth were finished, and all the host of them.",
"And on the seventh day God ended his work which he had made; and he rested on the seventh day from all his work which he had made.",
...
],
...
],
exodus: [
[ // first chapter
"Now these are the names of the children of Israel, which came into Egypt; every man and his household came with Jacob.",
...
],
...
],
...
};
使用这种结构,任何经文都应该非常快速地进行查找:要拉这本书,这是一个哈希映射查找,然后Chapter和verse是数组偏移量。
10-04 22:45