Codename One API
2099 documented types across 176 packages. Search the API from the site search, or download the whole reference as a zip.
com.codename1.ads | The modern, pluggable Codename One advertising API. |
com.codename1.ads.spi | Service provider interface (SPI) for the Codename One advertising API. |
com.codename1.ai | Codename One’s AI / LLM client surface plus the value types, streaming primitives, and chat-binding helpers that sit on top of it. |
com.codename1.ai.inference | Reusable on-device inference sessions for .tflite models. |
com.codename1.ai.language | Vendor-neutral on-device language identification, translation, and smart reply. |
com.codename1.ai.vision | Vendor-neutral on-device vision APIs for still images and live camera frames: barcodes and QR codes, OCR, faces, image labels, body pose, person segmentation, and document correction. |
com.codename1.analytics | The analytics API tracks how your application is used in the field through a generic provider SPI. |
com.codename1.annotations | Codename One specific Java annotations used by the build pipeline and the ParparVM bytecode translator to mark methods and classes for special treatment – e.g. opting individual call sites out of debug info or null/array-bounds checks, declaring asynchronous methods, or forcing a class to be treated as concrete during devirtualization. |
com.codename1.annotations.buildhints | Build hints expressed as annotations, so the compiler checks them. |
com.codename1.annotations.graphql | Annotations for declaring type safe GraphQL clients. |
com.codename1.annotations.grpc | gRPC-Web client annotations. |
com.codename1.annotations.rest | Annotations for declaring type safe REST clients. |
com.codename1.appreview | App review & feedback engagement API. |
com.codename1.ar | Cross-platform augmented reality: world tracking, plane detection, hit testing, anchors, 3D content placement, light estimation, image tracking and face tracking, backed by ARKit on iOS and ARCore on Android. |
com.codename1.background | Background fetch is a mechanism whereby an application is granted permission by the operating system to update its data periodically. |
com.codename1.binding | Runtime entry points for the build-time component-binding framework. |
com.codename1.bluetooth | Cross-platform Bluetooth API: adapter state, runtime permissions and capability queries. |
com.codename1.bluetooth.classic | Classic Bluetooth (BR/EDR): inquiry discovery (ClassicDiscovery), bonded-device listing and RFCOMM stream connections (RfcommConnection, RfcommServer). |
com.codename1.bluetooth.gatt | The client-side GATT model discovered on a remote peripheral: GattService, GattCharacteristic (read/write/subscribe), GattDescriptor, notification listeners and ATT status codes. |
com.codename1.bluetooth.le | BLE central role: scanning (BluetoothLE, ScanSettings, ScanFilter, ScanResult, BleScan), connections and the GATT client (BlePeripheral, connection events) and L2CAP connection-oriented channels (L2capChannel, L2capServer). |
com.codename1.bluetooth.le.server | BLE peripheral role: the local GATT server (GattServer, GattLocalService, GattLocalCharacteristic, request envelopes) and advertising (AdvertiseSettings, AdvertiseData, BleAdvertisement). |
com.codename1.calendar | Cross-platform access to local device calendars and explicitly registered online calendar sources. |
com.codename1.call | System call integration: making a call this app carries look, to the operating system and to the user, like a call the phone itself placed. |
com.codename1.call.directory | Naming and blocking numbers, for calls this app has nothing to do with. |
com.codename1.call.session | Reporting calls to the operating system, and hearing what the user does with them. |
com.codename1.call.spi | The seam between the portable com.codename1.call API and each platform’s native call stack. |
com.codename1.call.voip | Ringing when the app is not running. |
com.codename1.camera | Session based camera API for live preview, photo capture and video recording. |
com.codename1.capture | Package for capturing photos, audio or video from the camera/microphone. |
com.codename1.car | Portable in-car UI for Apple CarPlay and Google Android Auto. |
com.codename1.car.spi | Internal service-provider interface for the com.codename1.car in-car API. |
com.codename1.charts | The main ChartComponent Package |
com.codename1.charts.compat | This package contains compatibility classes for internal use |
com.codename1.charts.models | Provides the classes that handle the data values (data model) to be used by displaying the charts. |
com.codename1.charts.renderers | Provides renderer classes that keep the chart rendering / drawing styles. |
com.codename1.charts.transitions | Animated transitions between chart series states. |
com.codename1.charts.util | Utility classes that provide helper methods used by most of the other packages. |
com.codename1.charts.views | Provides the classes that handle the actual rendering / drawing of the charts, based on the provided model and renderer. |
com.codename1.cloud | Legacy cloud / property-binding hooks. |
com.codename1.codescan | Deprecated!!: Please use the cn1-codescan library instead. |
com.codename1.compat.java.util | Compatibility shims for java.util APIs that are not available on every Codename One target. |
com.codename1.components | Generic elaborate components that make use of both UI elements and storage. |
com.codename1.contacts | Provides access to the contacts list from the device address book |
com.codename1.continuity | Saves what the user was doing and brings it back – after the operating system kills the app, and on the other devices that person owns. |
com.codename1.continuity.spi | The platform seam of the continuity framework. |
com.codename1.continuity.sync | A small key/value store the platform carries between the devices one person is signed in to, for the handful of durable choices that should follow them everywhere. |
com.codename1.crash | On device crash protection client for Codename One applications. |
com.codename1.db | SQLite database access, with optional encryption at rest. |
com.codename1.documents | Exposes an app’s documents to the system file browser – the Files app on iOS and the storage picker on Android – so its content is browsable, and openable by other apps, without the app being launched. |
com.codename1.documents.spi | The platform seam of the document provider framework. |
com.codename1.facebook | Legacy generic implementation of the Facebook API with simplified OAuth integration to allow social sharing. |
com.codename1.facebook.ui | User interface for integrating with basic Facebook features currently mostly the Like button |
com.codename1.gaming | Game oriented APIs for Codename One. |
com.codename1.gaming.level | The saved-level / map model behind the Codename One game builder. |
com.codename1.gaming.physics | 2D rigid body physics for Codename One games. |
com.codename1.gaming.physics.box2d.callbacks | Listener and callback interfaces for the box2d physics engine (contact, query, ray cast and debug draw callbacks). |
com.codename1.gaming.physics.box2d.collision | Collision detection primitives (AABBs, manifolds, distance and time of impact queries) for the box2d physics engine. |
com.codename1.gaming.physics.box2d.collision.broadphase | Broad phase collision detection (dynamic tree and pair management) for the box2d physics engine. |
com.codename1.gaming.physics.box2d.collision.shapes | Collision shape definitions (circle, polygon, edge and chain) for the box2d physics engine. |
com.codename1.gaming.physics.box2d.common | Math and utility types (vectors, matrices, transforms and engine settings) shared across the box2d physics engine. |
com.codename1.gaming.physics.box2d.dynamics | Rigid body dynamics core (world, bodies, fixtures and the constraint solver) for the box2d physics engine. |
com.codename1.gaming.physics.box2d.dynamics.contacts | Contact constraints and contact solving for the box2d physics engine. |
com.codename1.gaming.physics.box2d.dynamics.joints | Joint constraints (revolute, prismatic, distance, weld and others) for the box2d physics engine. |
com.codename1.gaming.physics.box2d.pooling | Object pooling abstractions used to avoid allocations in the box2d physics engine. |
com.codename1.gaming.physics.box2d.pooling.arrays | Pooled reusable arrays used by the box2d physics engine. |
com.codename1.gaming.physics.box2d.pooling.normal | Default object pool implementations for the box2d physics engine. |
com.codename1.gaming.physics.box2d.pooling.stacks | Stack based object pools used by the box2d physics engine. |
com.codename1.gpu | Low level GPU accelerated graphics API for Codename One. |
com.codename1.health | Cross-platform health data: reading and writing samples, aggregating them over time, watching the store for changes, and recording workouts. |
com.codename1.health.nutrition | Logged food and drink, as a sparse set of nutrient amounts. |
com.codename1.health.sensors | Standard Bluetooth SIG health sensors – heart-rate straps, power meters, speed and cadence sensors, foot pods, thermometers, scales, blood-pressure cuffs and glucose meters. |
com.codename1.health.workout | Workout recording, live where the operating system supports it and framework-recorded everywhere else. |
com.codename1.home | A cross-platform smart-home API: read the home’s accessories, read and write what they can do, watch them for change, run scenes, and add new Matter accessories. |
com.codename1.home.commissioning | Adding a new Matter accessory to the user’s home. |
com.codename1.home.spi | The service-provider interface each platform port implements to back SmartHome. |
com.codename1.intents | App intents: the capabilities your application offers to the world outside it. |
com.codename1.intents.spi | The platform seam of the app intents framework. |
com.codename1.io | Networking, Storage, Filesystem & related API’s |
com.codename1.io.bonjour | Bonjour / mDNS-SD service discovery and publication. |
com.codename1.io.graphql | GraphQL client runtime. |
com.codename1.io.grpc | gRPC-Web client runtime. |
com.codename1.io.gzip | gzip support based on https://github.com/ymnk/jzlib |
com.codename1.io.oidc | OpenID Connect (OIDC) client with PKCE. |
com.codename1.io.rest | Simplified REST API |
com.codename1.io.services | Default WebService implementations |
com.codename1.io.tar | Tar support allowing us to package multiple separate files into a single package which is useful in supporting hierarchies in a portable way. |
com.codename1.io.usb | USB host-mode device access. |
com.codename1.io.webauthn | WebAuthn / passkey client. |
com.codename1.io.wifi | WiFi inspection, scanning, connection and peer-to-peer (WiFi Direct). |
com.codename1.javascript | NOTE: The com.codename1.javascript package is now deprecated. |
com.codename1.l10n | The Localization API allows developers to adapt their applications to different geographic locales and conventions. |
com.codename1.location | Abstraction of location services (GPS/Geofencing etc.) providing user global positioning and monitoring over such changes both in the foreground and background. |
com.codename1.mapping | Runtime entry points for the build-time JSON / XML mapping framework. |
com.codename1.maps | The mapping API allows developers to use maps in their applications, add layers on top of the map and to enhance the API with additional Layers, Providers and functionality. |
com.codename1.maps.layers | The Layers are elements that are displayed on the map. |
com.codename1.maps.providers | These are the map providers, currently http://www.openstreetmap.org/ is supported. |
com.codename1.maps.routing | Road-following routes for the modern maps API. |
com.codename1.maps.spi | The maps service-provider interface (SPI). |
com.codename1.maps.vector | The pure-vector map rendering engine that backs MapView. |
com.codename1.mcp | Model Context Protocol (MCP) headless API for Codename One applications. |
com.codename1.media | Video and Audio playback support are handled within this package using the com.codename1.media.Media & com.codename1.media.MediaManager APIs. |
com.codename1.messaging | Send e-mail messages through underlying platforms e-mail clients or thru the Codename One cloud. |
com.codename1.nearby | Nearby devices: how far away one is, which one is yours, and how to send it something. |
com.codename1.nearby.companion | Companion-device association: telling the operating system which accessory is yours, and getting privileges back for it. |
com.codename1.nearby.ranging | Ultra-wideband precision ranging: how far away another device is, and in which direction. |
com.codename1.nearby.spi | The service-provider interface each port implements to carry com.codename1.nearby onto the platform’s short-range stacks. |
com.codename1.nearby.transport | Sending bytes and files to a device in the same room, with no access point, no pairing and no internet. |
com.codename1.nfc | Near Field Communication (NFC) API: read and write NDEF messages, exchange APDUs with contactless smart cards, and host-emulate as a card. |
com.codename1.notifications | Local Notification API |
com.codename1.orm | Runtime entry points for the build-time SQLite ORM. |
com.codename1.payment | In-App Billing/Purchase API’s are abstracted by this package. |
com.codename1.plugin | Plugin SPI for extending core framework behaviour without subclassing. |
com.codename1.plugin.event | Typed events dispatched to plugins. |
com.codename1.printing | Cross platform printing: hand a PDF or image file to the platform printing system, which shows the native print dialog where the user picks a printer and confirms the job. |
com.codename1.processing | XPath based expression language designed to assist in JSON/XML parsing/generating |
com.codename1.properties | High level property objects that allow us to replace getters/setters in business objects with more convenient storage/parsing mappings while retaining type safety. |
com.codename1.push | Typed push notification registration, delivery, and custom transport APIs. |
com.codename1.router | Pop-navigation and deep-link routing support. |
com.codename1.security | Cryptographic primitives and conveniences: hashing, message authentication, symmetric/asymmetric encryption, digital signatures, JWTs, OTPs and random number generation. |
com.codename1.security.hardening | Read-only reporting of Codename One App Hardening status for the current build. |
com.codename1.security.shield | API shielding: attestation tokens, over-the-air certificate pinning, and runtime self-protection reporting. |
com.codename1.security.shield.spi | Service-provider interface between the public shield API and the attestation engine. |
com.codename1.sensors | Cross platform access to the device motion sensors and high level gesture detection. |
com.codename1.share | Sharing services, that can be registered on the ShareButton |
com.codename1.social | Connectors for native social network SDK’s |
com.codename1.surfaces | External surfaces: home-screen widgets and live activities from one declarative API. |
com.codename1.surfaces.spi | The platform seam of the external surfaces framework. |
com.codename1.system | Low level calls into the Codename One system, including support for making platform native API calls. |
com.codename1.testing | This package contains everything necessary for unit tests, automation of tests and everything in between. |
com.codename1.ui | Main widget package containing the component/container “composite” similar both in terminology and design to Swing/AWT. |
com.codename1.ui.accessibility | Defines the portable accessibility semantics tree for Codename One’s lightweight user-interface components. |
com.codename1.ui.animations | All components are animatable by potential and additional animations (unrelated to a specific component) can be installed on the fly, transitions between forms are also handled as part of this package. |
com.codename1.ui.css | Runtime CSS theme compilation. |
com.codename1.ui.editor | The pure Codename One text editing engine that backs com.codename1.ui.RichTextArea and com.codename1.ui.CodeEditor. |
com.codename1.ui.events | Observable pattern event listeners in the spirit of AWT 1.1’s event dispatching architecture, all events are dispatched on the EDT (Event Dispatch Thread). |
com.codename1.ui.geom | Contains classes related to geometry locations and calculations such as rectangle and size |
com.codename1.ui.html | This package is deprecated and used only for legacy support, use the WebBrowser component from the components package. |
com.codename1.ui.layouts | Layout managers allow a com.codename1.ui.Container to arrange its components by a set of rules that adapt to specific densities (ppi - pixels per inch). |
com.codename1.ui.layouts.mig | Codename One port of the MiG Layout manager. |
com.codename1.ui.list | Lists are highly customizable and serve as the basis for com.codename1.ui.ComboBox and other components (such as carousels etc) they employ a similar MVC approach to Swing including the renderer pattern, notice that we strongly discourage usage of lists… |
com.codename1.ui.painter | com.codename1.ui.Painter allows us to draw arbitrary elements of graphics from plain/scaled/tiled images to gradients and pretty much any form of graphic drawing we can imagine. |
com.codename1.ui.plaf | Look of the application can be fully customized via this package, it represents a rendering layer that can be plugged in separately in runtime and themed to provide any custom look. |
com.codename1.ui.scene | This package provides a light-weight scene graph for Codename One. |
com.codename1.ui.spinner | Spinners allows picking of simple sequential values similarly to combo boxes but of a much wider value set. |
com.codename1.ui.table | Table component for editing and viewing tabular data and arranging Codename One components in a tabular form |
com.codename1.ui.tree | Tree component for displaying hierarchy based information and its related classes |
com.codename1.ui.util | Utility features that are either too domain specific or don’t “fit” into any other packages including the Resource file format loading API. |
com.codename1.ui.validation | The validation framework allows us to mark invalid input in text components and disable components in the case of invalid input |
com.codename1.util | General utilities classes |
com.codename1.util.promise | JavaScript-style Promise for asynchronous Codename One code. |
com.codename1.util.regex | A simple regular expression API that is portable across all platforms |
com.codename1.vpn | Installing and controlling a VPN configuration. |
com.codename1.vpn.profile | Asking the operating system to run a standard VPN tunnel. |
com.codename1.vpn.spi | The seam between the portable com.codename1.vpn API and each platform’s native VPN machinery. |
com.codename1.vpn.tunnel | Writing the tunnel itself, rather than asking the system to run one. |
com.codename1.vr | Virtual reality and 360 media built entirely on the portable com.codename1.gpu pipeline and com.codename1.sensors motion sensors - no platform SDK dependency, so everything here runs wherever Display#isGpuSupported() is true, including the simulator. |
com.codename1.wearable | Talking between a phone app and its watch app. |
com.codename1.wearable.spi | Internal service-provider interface for the com.codename1.wearable phone-to-watch API. |
com.codename1.xml | The XML package allows parsing XML documents into DOM objects. |
java.io | |
java.lang | |
java.lang.annotation | |
java.lang.invoke | |
java.lang.ref | |
java.lang.reflect | |
java.net | |
java.nio.charset | |
java.text | |
java.time | |
java.time.format | |
java.time.temporal | |
java.util | |
java.util.concurrent | |
java.util.concurrent.atomic | |
java.util.function | |
java.util.stream |