Exit Print View

Java Platform Micro Edition Software Development Kit Version 3.0, Mac OS

Get PDF Book Print View
 

Document Information

Getting Started

Features

Using Sample Projects

Creating and Editing Projects

Viewing and Editing Project Properties

Running Projects in the Emulator

Searching the WURFL Device Database

Finding Files in the Multiple User Environment

Profiling Applications

Network Monitoring

Lightweight UI Toolkit

Security and MIDlet Signing

CLDC Emulation on a Windows Mobile Device

Installing CLDC Emulation on a Windows Mobile Emulator (Windows Only)

On-device Debugging

Command Line Reference

Logs

JSR Support

JSR 75: PDA Optional Packages

FileConnection API

PIM API

Running PDAPDemo

JSR 82: Bluetooth and OBEX Support

JSR 135: Mobile Media API Support

JSR 172: Web Services Support

JSR 177: Smart Card Security (SATSA)

JSR 179: Location API Support

JSR 180: SIP Communications

JSR 184: Mobile 3D Graphics

JSR 205: Wireless Messaging API (WMA) Support

JSR 211: Content Handler API (CHAPI)

JSR 226: Scalable 2D Vector Graphics

JSR 229: Payment API Support

JSR 238: Mobile Internationalization API (MIA)

JSR 256: Mobile Sensor API Support

Index


FileConnection API

On a real device, the FileConnection API typically provides access to files stored in the device’s memory or on a memory card.

In the Java ME Platform SDK emulator, the FileConnection API enables MIDlets to access files stored on your computer’s hard disk.

The files that can be accessed using FileConnection are stored in the following subdirectory:

Windows

Documents and Settings\User\Application Support\javame-sdk\3.0\work\emulator-instance\appdb\filesystem

Mac OS

User/Application Support/javame-sdk/3.0/work/emulator-instance/appdb/filesystem

For example, the DefaultCldcPhone1 emulator instance comes with a root directory installed called root1, which contains a Readme file and an empty directory named photos.

Each subdirectory of filesystem is called a root. The Java ME Platform SDK provides a mechanism for managing roots. While the emulator is running, choose View > External Events Generator from the emulator window’s menu. A utility window opens. Click the File Connection tab.

External event generator window with File Connection tab selected

In the File Connection panel you can mount, unmount, or delete filesystem roots. Mounted roots are displayed in the top list, and unmounted roots are moved to the bottom list. Mounted root directories and their subdirectories are available to applications using the FileConnection API. Unmounted roots can be remounted in the future.