Q. Can I tell what all the system resources are, just by their names?

A. Sometimes you can't. The official documentation for the Android system resources does not describe each resource. If you are confused about what a specific system resource is or how it works, you can either experiment with it or examine its resource definition. Android system resources are defined in the /tools/lib/res/default directory of the Android SDK.

Q. Must string, color, and dimension resources be stored in separate XML files?

A. Technically, no. However, it is highly recommended. For example, localization and internationalization may require different strings, but the dimensions might remain the same ones. Keeping the resource types separate keeps them organized.

Q. Which XML parser should I use?

A. Our tests have shown that the SAX parser is the most efficient XML parser (closely followed by XMLPullParser), and we recommend this parser for most purposes. However, the choice is yours, and you should test your specific XML implementation to determine the appropriate parser for your application's needs.

Q. What is the difference between project resources and project assets?

A. Project resources are compiled into the application and easily accessed using the getResources() method. Application assets are used less frequently to store uncompiled files within the application package file that is installed on the handset. Assets are accessed using the getAssets() method.

0 0

Post a comment