Class HostController
Interface of HostController.
Inherited Members
Namespace: DotNetNuke.Entities.Controllers
Assembly: DotNetNuke.dll
Syntax
public class HostController : ComponentBase<IHostController, HostController>, IHostController, IHostSettingsService
Constructors
| Improve this Doc View SourceHostController()
Initializes a new instance of the HostController class.
Declaration
public HostController()
See Also
Properties
| Improve this Doc View SourceInstance
Interface of HostController.
Declaration
public static IHostController Instance { get; }
Property Value
Type | Description |
---|---|
IHostController |
See Also
Methods
| Improve this Doc View SourceGetBoolean(String, Boolean)
Gets the setting value for the specific key.
Declaration
public bool GetBoolean(string key, bool defaultValue)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
System.Boolean | defaultValue | Default value returned if the setting is not found or not compatible with the requested type. |
Returns
Type | Description |
---|---|
System.Boolean | host setting or the provided default value as a |
See Also
| Improve this Doc View SourceGetBoolean(String)
Gets the setting value for the specific key.
Declaration
public bool GetBoolean(string key)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
Returns
Type | Description |
---|---|
System.Boolean | host setting as a boolean. |
See Also
| Improve this Doc View SourceGetDouble(String, Double)
Gets the setting value for the specific key.
Declaration
public double GetDouble(string key, double defaultValue)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
System.Double | defaultValue | Default value returned if the setting is not found or not compatible with the requested type. |
Returns
Type | Description |
---|---|
System.Double | Host setting or the provided default value as a |
See Also
| Improve this Doc View SourceGetDouble(String)
Gets the setting value for the specific key.
Declaration
public double GetDouble(string key)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
Returns
Type | Description |
---|---|
System.Double | Host setting as a |
See Also
| Improve this Doc View SourceGetEncryptedString(String, String)
Gets an encrypted host setting as a
Declaration
public string GetEncryptedString(string key, string passPhrase)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
System.String | passPhrase | The passPhrase used to decrypt the setting value. |
Returns
Type | Description |
---|---|
System.String | The setting value as a |
See Also
| Improve this Doc View SourceGetInteger(String, Int32)
Gets the setting value for the specific key.
Declaration
public int GetInteger(string key, int defaultValue)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
System.Int32 | defaultValue | Default value returned if the setting is not found or not compatible with the requested type. |
Returns
Type | Description |
---|---|
System.Int32 | Host setting or provided default value as a |
See Also
| Improve this Doc View SourceGetInteger(String)
Gets the setting value for the specific key.
Declaration
public int GetInteger(string key)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
Returns
Type | Description |
---|---|
System.Int32 | Host setting as an |
See Also
| Improve this Doc View SourceGetSettings()
Gets all host settings.
Declaration
public Dictionary<string, ConfigurationSetting> GetSettings()
Returns
Type | Description |
---|---|
Dictionary<System.String, ConfigurationSetting> | host setting. |
See Also
| Improve this Doc View SourceGetSettingsDictionary()
Gets all host settings as dictionary.
Declaration
public Dictionary<string, string> GetSettingsDictionary()
Returns
Type | Description |
---|---|
Dictionary<System.String, System.String> | host setting's value. |
See Also
| Improve this Doc View SourceGetString(String, String)
Gets the setting value for a specific key.
Declaration
public string GetString(string key, string defaultValue)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The seeting key string. |
System.String | defaultValue |
Returns
Type | Description |
---|---|
System.String | Default value returned if the setting is not found. |
See Also
| Improve this Doc View SourceGetString(String)
Gets the setting value for a specific key.
Declaration
public string GetString(string key)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
Returns
Type | Description |
---|---|
System.String | The setting value as a |
See Also
| Improve this Doc View SourceIncrementCrmVersion(Boolean)
Increments the Client Resource Manager (CRM) version to bust local cache.
Declaration
public void IncrementCrmVersion(bool includeOverridingPortals)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | includeOverridingPortals | If true also forces a CRM version increment on portals that have non-default settings for CRM. |
See Also
| Improve this Doc View SourceUpdate(Dictionary<String, String>)
Updates the specified settings.
Declaration
public void Update(Dictionary<string, string> settings)
Parameters
Type | Name | Description |
---|---|---|
Dictionary<System.String, System.String> | settings | The settings to update. |
See Also
| Improve this Doc View SourceUpdate(IConfigurationSetting, Boolean)
Interface of HostController.
Declaration
public void Update(IConfigurationSetting config, bool clearCache)
Parameters
Type | Name | Description |
---|---|---|
IConfigurationSetting | config | |
System.Boolean | clearCache |
See Also
| Improve this Doc View SourceUpdate(IConfigurationSetting)
Updates the specified config.
Declaration
public void Update(IConfigurationSetting config)
Parameters
Type | Name | Description |
---|---|---|
IConfigurationSetting | config | The config. |
See Also
| Improve this Doc View SourceUpdate(ConfigurationSetting, Boolean)
Updates the specified config, ontionally clearing the cache.
Declaration
public void Update(ConfigurationSetting config, bool clearCache)
Parameters
Type | Name | Description |
---|---|---|
ConfigurationSetting | config | The configuaration setting. |
System.Boolean | clearCache | If set to |
See Also
| Improve this Doc View SourceUpdate(ConfigurationSetting)
Updates the specified config.
Declaration
public void Update(ConfigurationSetting config)
Parameters
Type | Name | Description |
---|---|---|
ConfigurationSetting | config | The configuration setting. |
See Also
| Improve this Doc View SourceUpdate(String, String, Boolean)
Updates the setting for a specific key.
Declaration
public void Update(string key, string value, bool clearCache)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
System.String | value | The value to update. |
System.Boolean | clearCache | If set to |
See Also
| Improve this Doc View SourceUpdate(String, String)
Updates the setting for a specific key.
Declaration
public void Update(string key, string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | The setting key string. |
System.String | value | The value to update. |
See Also
| Improve this Doc View SourceUpdateEncryptedString(String, String, String)
Takes in a
Declaration
public void UpdateEncryptedString(string key, string value, string passPhrase)
Parameters
Type | Name | Description |
---|---|---|
System.String | key | host settings key. |
System.String | value | host settings value. |
System.String | passPhrase | pass phrase to allow encryption/decryption. |