Oh sorry, yeah those are not part of the NDK.  However you should be able to
use the Java API to open a FileDescriptor for an asset, and hand that to
native code for it to use the fd.  The only limitation is that the asset
will need to be stored uncompressed.  (Alternatively, an .apk is just a zip
file, so worst case you could compile the zip code into your app and use
that to extract the file you want.)

On Tue, Jul 7, 2009 at 11:54 PM, nEx.Software <justin.shapc...@gmail.com>wrote:

>
> So, I've been looking over the LatinIME in the git repository, and I
> am getting the feeling that this (the native dictionary piece) can't
> be compiled on the NDK - at least not officially? There seem to be
> some unsupported libraries and such being used. Specifically, Asset.h
> and AssetManager.h which look to be a part of the base/include/utils
> portion of the source tree. I assume these are not a part of the NDK
> scope at this point?
>
> On Jul 7, 4:13 pm, "nEx.Software" <justin.shapc...@gmail.com> wrote:
> > Awesome, thanks for the info. I had a feeling that was the case.
> > Thanks for confirming that for me.
> >
> > On Jul 7, 3:04 pm, Dianne Hackborn <hack...@android.com> wrote:
> >
> >
> >
> > > The prediction dictionary is built into the IME, it is not a part of
> the
> > > platform like the user dictionary, so you will need to implement your
> own
> > > for your IME.  The LatinIME code is open source, so to start you can
> just
> > > copy it (especially now that we have the NDK available).
> >
> > > On Tue, Jul 7, 2009 at 2:56 PM, nEx.Software <
> justin.shapc...@gmail.com>wrote:
> >
> > > > I am attempting to do an IME and am wondering the best way to use the
> > > > main dictionary for the suggestions to work? Using the User
> Dictionary
> > > > is pretty straight forward, but I am not sure how to use the main
> > > > dictionary. The System IME appears to use BinaryDictionary and a
> > > > native method to do this? Can I piggy back on this or must I create
> my
> > > > own implementation? Thanks in advance.
> >
> > > --
> > > Dianne Hackborn
> > > Android framework engineer
> > > hack...@android.com
> >
> > > Note: please don't send private questions to me, as I don't have time
> to
> > > provide private support, and so won't reply to such e-mails.  All such
> > > questions should be posted on public forums, where I and others can see
> and
> > > answer them.
> >
>


-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to