Immutable record of a single app's enabled state and settings within a website's WebsiteSettings, serialised as an "app" element in settings.xml. Constructed with an app instance id, an enabled flag and a settings map; the set and setEnabled methods each return a new AppSettingsBean rather than mutating this one.
Group: Website Settings
Implements: AppSettings
Properties
| Property | Returns | Description |
|---|---|---|
| appInstanceId | String | The id of the app instance these settings apply to. |
| enabled | boolean | Whether this app is enabled for the website. |
| settings | Map<String,String> | The settings recorded for this app. |
| version | String | The value of the "version" setting for this app, if one has been recorded. |
Methods
getAppInstanceId()
Returns: String
The id of the app instance these settings apply to.
getVersion()
Returns: String
The value of the "version" setting for this app, if one has been recorded.
isEnabled()
Returns: boolean
Whether this app is enabled for the website.
getSettings()
Returns: Map<String,String>
The settings recorded for this app.
set(String settingName, String value)
Returns: AppSettingsBean
Returns a new AppSettingsBean with the given setting added or replaced. This instance is not modified.
| Parameter | Description |
|---|---|
settingName | the name of the setting to set |
value | the value to set it to |
setEnabled(boolean newEnabled)
Returns: AppSettingsBean
Returns a new AppSettingsBean with the enabled flag changed, keeping the same app instance id and settings. This instance is not modified.
| Parameter | Description |
|---|---|
newEnabled | the enabled flag to set on the new instance |