iPhone SDK doesn’t support Java for the development code. Neither does Java runs on iPhone (though you can Compile, Run, Install Java apps on iPhone by jailbreaking). But there is just one legal way of developing applications in Java for the iPhone: using PrimeFaces.
PrimeFaces is an Open Source library for JSF which lets you create a rich set of components and provide non-rendering JSF extensions to ease development on various webapps. Though not intended for iPhone alone, it serves iPohne webapps quiet efficiently.
PrimeFaces basically has 3 components: UI, Optimus, FaceTrace. Details are available on the PrimeFaces site.
The framework is very powerful and Rich in UI. It has built-in 50+ AJAX based functions that serve most of the effects you would typically need to design iPhone apps.
To demonstrate the power, a developer has hosted a webpage dedicated to the webapps iPhone can run, just like it does any Native application and the corresponding source code is available on Google code.
Checkout the Video for iPhone sample apps: