如何在带有 Monotouch for iOS 的 SQLite 中使用 FTS [英] How to use FTS in SQLite with Monotouch for iOS

查看:29
本文介绍了如何在带有 Monotouch for iOS 的 SQLite 中使用 FTS的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望使用 Monotouch 构建一个 iOS 应用程序,该应用程序具有相当大的充满文本的 sqlite 数据库.我需要提供对该文本的快速搜索.

I'm looking to build an iOS app using Monotouch that has a rather large sqlite db full of text. I need to provide fast searching over this text.

我现在最好的解决方案是 FTS 模块(最好是版本 4).我已经读到 iOS 上的默认 sqlite 实例不支持 FTS.如果这是真的,使用 Monotouch 构建 sqlite 的自定义实例的推荐方法是什么?或者这完全可以做到吗?

My best solution right now is the FTS module (preferably version 4). I have read that the default instance of sqlite on iOS does not support FTS. If this is true what is the recommended way to build a custom instance of sqlite with Monotouch? Or can this be done at all?

我发现这个网站描述了如何使用 xcode 完成此操作,但不清楚我将如何使用 Monotouch 完成此操作.
http://longweekendmobile.com/2010/06/16/sqlite-full-text-search-for-iphone-ipadyour-own-sqlite-for-iphone-and-ipad/

I found this site describing how to accomplish this with xcode, but it is not clear how I would accomplish with Monotouch.
http://longweekendmobile.com/2010/06/16/sqlite-full-text-search-for-iphone-ipadyour-own-sqlite-for-iphone-and-ipad/

非常感谢任何帮助!

推荐答案

你必须做同样的事情,构建你自己的 libsqlite3.a,并处理所有公共导出,这样它就不会与加载的 libsqlite 冲突系统,然后您需要将要绑定到 sqlite 的任何库修改为 [DllImport ("__Internal")] 而不是 libsqlite.

You would have to do the same thing, build your own libsqlite3.a, and mangle all the public exports so it doesn't conflict with the libsqlite loaded by the system, and then you would need to modify whatever library you want to bind to sqlite to [DllImport ("__Internal")] instead of libsqlite.

这篇关于如何在带有 Monotouch for iOS 的 SQLite 中使用 FTS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆