Question: Let's say I have three tables: `users`, `books`, and `users_books`.

In one of my views, I want to display a list of all the books the current user has access to. A user has access to a book if a row matching a user and a book exists in `users_books`.

There are (at least) two ways I can accomplish this:

* In my `fetchAll()` method in the `books` model, execute a `join` of some sort on the `users_books` table.
* In an Acl plugin, first create a resource out of every book. Then, create a role out of every user. Next, allow or deny users access to each resource based on the `users_books` table. Finally, in the `fetchAll()` method of the `books` model, call `isAllowed()` on each book we find, using the current user as the role.

I see the last option as the best, because then I could use the Acl in other places in my application. That would remove the need to perform duplicate access checks.

What would you suggest?

Answer: 
There isn't any way to compile Android apps from Xcode, and i strongly doubt that Apple would introduce such a feature - if it's even technically possible to do. Sorry.

But if you have Objective C down, you shouldn't have to much problems understanding Java (which is used for creating Android apps).

Check the link below for a pretty comprehensive guide to start learning java and code for the Android platform:

<http://mobile.tutsplus.com/tutorials/android/java-tutorial/>

Good luck!
No, in general you can't do this. Even if assuming Objective-C can be compiled/converted into Java (which is most likely will not be true for times to come), you'll need to rewrite UI part; then most of OS APIs are different too. There are several features that iOS has that Android lacks or does not have open API for it, or has limited API, or has conceptually different or just different API.

Its just easier to move some of your iOS code into C/C++ shared library and then make sure that it compiles and works on both platforms. And then make platform dependent pieces separately for each platform (UI, hardware related stuff, etc.). This way you'll have at least part of your code shared.