Tip

MIDP system properties

MIDP stands for mobile information device profile and if you want to understand the MIDP programming model you have to consider the properties and attributes of the devices that you want your applications, or MIDlets, to run on.

All MIDlets have associated properties and attributes. Properties are standard system properties defined by the CLDC (connected limited device configuration) specification. They pertain to the platform and are maintained and managed by the application management system. Attributes are associated with MIDlets. There are required attributes that are available to all MIDlets, and there are optional attributes.

This short excerpt by Vartan Piroumian from

    Requires Free Membership to View

InformIT, looks at the standard MIDP system properties and how to retrieve these properties.


The CLDC/MIDP supports system properties, which are key-value pairs that represent information about the platform and environment in which MIDP applications execute. Conceptually these are the same type of properties that you find in J2SE. Unfortunately, there is no java.util.Properties class in CLDC/MIDP to facilitate your handling of properties.

The MIDP specification defines only a small set of standard properties, which are shown in the table below. Implementations may support additional, manufacturer-specific system properties, but these are nonstandard. You should be aware of what manufacturer- or platform-specific features you use in order to anticipate portability issues.

Like J2SE applications, MIDP applications can retrieve a system property using the java.lang.System class. To retrieve the value of a property, use the System class method

String getProperty(String key)

This method retrieves the property value associated with the key whose value is specified in the call.

Standard CLDC System Properties
Property Key Description Default Value
microedition.configuration Name and version of the supported configuration CLDC-1.0
microedition.encoding Default character encoding set used by the platform ISO8859-1
microedition.locale Name of the platform's current locale null
microedition.platform Name of the host platform or device null
microedition.profiles Names of all supported profiles null

Read more about wireless J2ME platform programming at InformIT.


This was first published in February 2004

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

Disclaimer: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.