BT_config.txt
Information about how the application looks, the layout it uses, and it's overall functionality
is saved in one main configuration file, BT_config.txt. This is a plain text file
organized in JSON format.
This file can be edited using the buzztouch control panel or it can be edited
manually with any text editor.
Configuration Data Location
The main configuration data file is part of the Xcode or Eclipse project. Most applications also
use a configuration file that resides on a remote server.
This approach allows the application to dynamically update itself when content
changes occur on the remote server. The remote server is usually the buzztouch control panel
but could also be your own website or other online document storage solution such as
DropBox™
How Configuration Data is Processed
Here are the basics steps the mobile app works through when reading it's configuration data.
-
App launches.
-
App looks for a cached copy of it's configuration data in it's local data storage.
This is different than the copy in the Xcode or Eclipse project (see #5).
-
If a copy of the BT_config.txt file is found in the apps local data storage it reads
that file and ignores the file included in the Xcode or Android project. This means the
app downloaded and saved data from a remote configuration file.
-
If a copy of the BT_config.txt file is not found in the apps local data storage it reads
the file included in the Xcode or Eclipse project. If this file includes a URL that points
to a remote server, it downloads the file then saves it for future use (see #1). In this case,
the file included in the Xcode or Eclipse project is not used again unless the app's cached-data is
removed from the device.
-
If no URL is provided for a remote server, the app uses the BT_config.txt file
in the Xcode or Eclipse project everytime and does not attempt to download anything from the internet.
Configuration Data Properites
BT_config
|
"BT_config":{}
This object wraps the entire JSON structure and all other objects.
|
BT_items
|
"BT_items":[]
An array with one and only one BT_item, this item is of type BT_app. The BT_app item
holds all the configuration data for the app.
|
Item Id
|
"itemId":"a unique id"
A unique id identifiying this item from all other items in the
entire JSON structure.
|
Item Type
|
"itemType":"BT_app"
Identifies this type of item as a BT_app item.
|
buzztouch App Id
|
"buzztouchAppId":"88473748399284"
The unique id identifying this buzztouch app. Ignorned if the app is not
connected to the buzztouch control panel.
|
buzztouch API Key
|
"buzztouchAPIKey":"995839483828"
The API key identifying this buzztouch app. Ignorned if the app is not
connected to the buzztouch control panel.
|
Configuration Data URL
|
"dataURL":"an internet address"
An internet address leading to the app's remote configuration
file. This is normally a URL leading to the configuration data controlled by the
buzztouch control panel. It could also lead to a
configuration file saved on your website or online document storage folder.
BT_config.txt in the Xcode or Eclipse project
is used if this is not provided. This URL works closely with the reportToCloudURL.
|
Report To Cloud URL
|
"reportToCloudURL":"an internet address"
An internet address leading to a remote-script that determines if the app's content
or layout needs updated. This is optional if a dataURL is not
provided. This is required if a dataURL is provided.
See more about the Report to Cloud URL.
|
Name
|
"name":"My Cool App"
The name of the app in the buzztouch control panel.
|
Version
|
"version":"1.5"
The buzztouch version.
|
Start Location Updates
|
"startLocationUpdates":"1"
Options: 0 or 1. 0 means "do not turn on the GPS when the app
launches.
|
Allow Rotation
|
"allowRotation":"allDevices"
Options: allDevices, largeDevicesOnly. Setting this to largeDevicesOnly will prevent
small devices from swithing to landscape view when the device is rotated.
|
Themes
|
"BT_themes":[]
An array containing one and only one entry, a BT_theme object.
|
Tabs
|
"BT_tabs":[]
An array containing from 0 to 5 BT_tab objects.
If this array is empty, the app will use a non-tabbed layout.
If tabs are used, each tab will use a BT_screen object
for it's home screen.
|
Screens
|
"BT_screens":[]
An array containing from 1 to X Screen or Menu objects.
Each object in this list represents a screen or feature found in the app.
|
|