Header
Home | Sitemap  
Sections
Archive
Su Mo Tu We Th Fr Sa
1
2345678
9101112131415
16171819202122
23242526272829
30
Syndication



Application Resource Files

by

image

 

Application Resource Files

MIDP provides the capability of storing resources in the application's JAR that can be accessed by a MIDlet at run time. An example of such a resource might be a locale bundle, an icon, or a graphical image; however, any thing that can be accessed as an InputStream can also be stored. These resources are accessed using the method getResourceAsStream(String name) of class java.lang.Class.

The rules and the parameter string format for accessing resources inside a JAR file have been discussed in Section 19.1.4, "MIDlet Suite Execution Environment." As a general rule, if the parameter string to the getResourceAsStream method begins with a '/', the search for the resource begins at the "root" of the JAR file; however, if it does not begin with a '/', the resource is searched for along a path relative to the class instance retrieving the resource.

214 times read

Related news

» Using Resource Files
by admin posted on Nov 17,2006
» MIDlet Suites
by admin posted on Jul 08,2007
» Designing and Coding
by admin posted on Sep 26,2007
» Application Properties
by admin posted on Sep 26,2007
» Packaging
by admin posted on Sep 26,2007


More Top News
Cisco Wireless Networking
Most Popular
Featured Author