• Share
    • Twitter
    • LinkedIn
    • Facebook
    • Email
  • Feedback
  • Improve this Doc

Class HostController

Interface of HostController.

Inheritance
System.Object
ComponentBase<IHostController, HostController>
HostController
Implements
IHostController
IHostSettingsService
Inherited Members
ComponentBase<IHostController, HostController>.Instance
ComponentBase<IHostController, HostController>.RegisterInstance(IHostController)
Namespace: DotNetNuke.Entities.Controllers
Assembly: DotNetNuke.dll
Syntax
public class HostController : ComponentBase<IHostController, HostController>, IHostController, IHostSettingsService

Constructors

| Improve this Doc View Source

HostController()

Initializes a new instance of the HostController class.

Declaration
public HostController()
See Also
HostController

Properties

| Improve this Doc View Source

Instance

Interface of HostController.

Declaration
public static IHostController Instance { get; }
Property Value
Type Description
IHostController
See Also
HostController

Methods

| Improve this Doc View Source

GetBoolean(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
HostController
| Improve this Doc View Source

GetBoolean(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
HostController
| Improve this Doc View Source

GetDouble(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
HostController
| Improve this Doc View Source

GetDouble(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
HostController
| Improve this Doc View Source

GetEncryptedString(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
HostController
| Improve this Doc View Source

GetInteger(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
HostController
| Improve this Doc View Source

GetInteger(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
HostController
| Improve this Doc View Source

GetSettings()

Gets all host settings.

Declaration
public Dictionary<string, ConfigurationSetting> GetSettings()
Returns
Type Description
Dictionary<System.String, ConfigurationSetting>

host setting.

See Also
HostController
| Improve this Doc View Source

GetSettingsDictionary()

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
HostController
| Improve this Doc View Source

GetString(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
HostController
| Improve this Doc View Source

GetString(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
HostController
| Improve this Doc View Source

IncrementCrmVersion(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
HostController
| Improve this Doc View Source

Update(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
HostController
| Improve this Doc View Source

Update(IConfigurationSetting, Boolean)

Interface of HostController.

Declaration
public void Update(IConfigurationSetting config, bool clearCache)
Parameters
Type Name Description
IConfigurationSetting config
System.Boolean clearCache
See Also
HostController
| Improve this Doc View Source

Update(IConfigurationSetting)

Updates the specified config.

Declaration
public void Update(IConfigurationSetting config)
Parameters
Type Name Description
IConfigurationSetting config

The config.

See Also
HostController
| Improve this Doc View Source

Update(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 true, will clear the cache after updating the setting.

See Also
HostController
| Improve this Doc View Source

Update(ConfigurationSetting)

Updates the specified config.

Declaration
public void Update(ConfigurationSetting config)
Parameters
Type Name Description
ConfigurationSetting config

The configuration setting.

See Also
HostController
| Improve this Doc View Source

Update(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 true, will clear the cache after updating the setting.

See Also
HostController
| Improve this Doc View Source

Update(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
HostController
| Improve this Doc View Source

UpdateEncryptedString(String, String, String)

Takes in a value, encrypts it with a FIPS compliant algorithm and stores.

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.

See Also
HostController

Implements

IHostController
IHostSettingsService

Extension Methods

JsonExtensionsWeb.ToJson(Object)

See Also

HostController
  • View Source
Back to top by the community, for the community... #DNNCMS