Table of Contents

Class AppSettingsHelper

Namespace: Casewhere.Common
Assembly: Casewhere.Common.dll

public static class AppSettingsHelper

Inheritance

objectAppSettingsHelper

Inherited Members

object.ToString(), object.Equals(object), object.Equals(object, object), object.ReferenceEquals(object, object), object.GetHashCode(), object.GetType(), object.MemberwiseClone()

Extension Methods

ObjectExtension.ConvertToBsonValue(object)

Methods

ReadBoolean(string)

public static bool ReadBoolean(string key)

Parameters

key string

Returns

bool

ReadEnum<T>(string)

public static T ReadEnum<T>(string key) where T : struct, IConvertible

Parameters

key string

Returns

T

Type Parameters

T

ReadInt(string)

public static int ReadInt(string key)

Parameters

key string

Returns

int

ReadString(string)

public static string ReadString(string key)

Parameters

key string

Returns

string

ReadTimeSpan(string)

public static TimeSpan ReadTimeSpan(string key)

Parameters

key string

Returns

TimeSpan

ReadTimeSpanHours(string, TimeSpan)

public static TimeSpan ReadTimeSpanHours(string key, TimeSpan defaultValue = default)

Parameters

key string

defaultValue TimeSpan

Returns

TimeSpan

ReadTimeSpanSeconds(string, TimeSpan)

public static TimeSpan ReadTimeSpanSeconds(string key, TimeSpan defaultValue = default)

Parameters

key string

defaultValue TimeSpan

Returns

TimeSpan