Module: Toybox.Application
Overview
The Application module contains the base class for every Connect IQ app.
The Application Module includes the AppBase class which is responsible for controlling the app life cycle. This module also includes set and get methods to control the settings and properties values held in the Object Store and a GOAL_TYPE enum that defines the different goal types that can be triggered.
See Also:
Modules Under Namespace
Modules: Application.Properties, Application.Storage
Classes Under Namespace
Classes: AppBase, AudioContentProviderApp, ObjectStoreAccessException
Constant Summary
-
GoalType
Name | Value | Since | Description | See Also |
---|---|---|---|---|
GOAL_TYPE_STEPS | 0 | API Level 1.3.0 |
||
GOAL_TYPE_FLOORS_CLIMBED | 1 | API Level 1.3.0 |
||
GOAL_TYPE_ACTIVE_MINUTES | 2 | API Level 1.3.0 |
Typedef Summary collapse
- PersistableType as Application.PropertyValueType
- PropertyKeyType as Lang.Number or Lang.Float or Lang.Long or Lang.Double or Lang.String or Lang.Boolean or Lang.Char
- PropertyValueType as Application.PropertyKeyType or Lang.Array<Application.PropertyValueType> or Lang.Dictionary<Application.PropertyKeyType, Application.PropertyValueType> or WatchUi.BitmapResource or Null
- ResourceReferenceType as Graphics.BitmapReference or Graphics.FontReference
- ResourceType as Lang.Array or Lang.Dictionary or Lang.String or WatchUi.AnimationResource or WatchUi.BitmapResource or WatchUi.FontResource
Instance Method Summary collapse
-
getApp() as Application.AppBase
Retrieve the AppBase Object that is currently running.
-
loadResource(resource as Lang.ResourceId) as Application.ResourceType or Application.ResourceReferenceType
Load a resource from the executable.
Typedef Details
PersistableType as Application.PropertyValueType
PropertyKeyType as Lang.Number or Lang.Float or Lang.Long or Lang.Double or Lang.String or Lang.Boolean or Lang.Char
PropertyValueType as Application.PropertyKeyType or Lang.Array<Application.PropertyValueType> or Lang.Dictionary<Application.PropertyKeyType, Application.PropertyValueType> or WatchUi.BitmapResource or Null
ResourceReferenceType as Graphics.BitmapReference or Graphics.FontReference
ResourceType as Lang.Array or Lang.Dictionary or Lang.String or WatchUi.AnimationResource or WatchUi.BitmapResource or WatchUi.FontResource
Instance Method Details
getApp() as Application.AppBase
Retrieve the AppBase Object that is currently running.
loadResource(resource as Lang.ResourceId) as Application.ResourceType or Application.ResourceReferenceType
Load a resource from the executable.
Toybox::Graphics::BitmapReference and Toybox::Graphics::FontReference are returned for Toybox::WatchUi::BitmapResource and Toybox::WatchUi::FontResource in CIQ 4.0.0 and later.