Show / Hide Table of Contents

Class App

Provides a shortcut access to app-global context NFX.ApplicationModel.ExecutionContext.Application.*

Inheritance
System.Object
App
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: NFX
Assembly: NFX.dll
Syntax
public static class App

Properties

Active

Returns true when application instance is active and working. This property returns false as soon as application finalization starts on shutdown Use to exit long-running loops and such

Declaration
public static bool Active { get; }
Property Value
Type Description
System.Boolean

Available

Returns true when application container is active non-NOPApplication instance

Declaration
public static bool Available { get; }
Property Value
Type Description
System.Boolean

ConfigRoot

References application configuration root

Declaration
public static IConfigSectionNode ConfigRoot { get; }
Property Value
Type Description
IConfigSectionNode

CurrentCallUser

Returns the current call context user

Declaration
public static User CurrentCallUser { get; }
Property Value
Type Description
User

DataStore

References application data store

Declaration
public static IDataStore DataStore { get; }
Property Value
Type Description
IDataStore

EventTimer

References event timer that maintains and runs scheduled Event instances

Declaration
public static IEventTimer EventTimer { get; }
Property Value
Type Description
IEventTimer

Glue

References glue implementation that may be used to "glue" remote instances/processes/contracts together

Declaration
public static IGlue Glue { get; }
Property Value
Type Description
IGlue

Instance

Declaration
public static IApplication Instance { get; }
Property Value
Type Description
IApplication

InstanceID

Returns unique identifier of this running instance

Declaration
public static Guid InstanceID { get; }
Property Value
Type Description
System.Guid

Instrumentation

References instrumentation for this application instance

Declaration
public static IInstrumentation Instrumentation { get; }
Property Value
Type Description
IInstrumentation

LocalizedTime

Returns current time localized per TimeLocation

Declaration
public static DateTime LocalizedTime { get; }
Property Value
Type Description
System.DateTime

Log

References app log

Declaration
public static ILog Log { get; }
Property Value
Type Description
ILog

MemoryModel

Returns the memory utilization model for the application. This property is NOT configurable. It may be set at process entrypoint via a call to App.SetMemoryModel() before the app contrainer spawns. Typical applications should not change the defaults. Some system service providers examine this property to allocate less cache and temp buffers in the memory-constrained environments

Declaration
public static App.MemoryUtilizationModel MemoryModel { get; }
Property Value
Type Description
App.MemoryUtilizationModel

ModuleRoot

References the root module (such as business domain logic root) for this application. This is a dependency injection root provided for any application type

Declaration
public static IModule ModuleRoot { get; }
Property Value
Type Description
IModule

Name

Returns application name

Declaration
public static string Name { get; }
Property Value
Type Description
System.String

ObjectStore

References object store that may be used to persist object graphs between volatile application shutdown cycles

Declaration
public static IObjectStore ObjectStore { get; }
Property Value
Type Description
IObjectStore

SecurityManager

References security manager that performs user authentication based on passed credentials and other security-related global tasks

Declaration
public static ISecurityManager SecurityManager { get; }
Property Value
Type Description
ISecurityManager

Session

Returns current session, this is a shortuct to ExecutionContext.Session

Declaration
public static ISession Session { get; }
Property Value
Type Description
ISession

StartTime

Returns timestamp when application started as localized app time

Declaration
public static DateTime StartTime { get; }
Property Value
Type Description
System.DateTime

TimeLocation

Returns the location

Declaration
public static TimeLocation TimeLocation { get; }
Property Value
Type Description
TimeLocation

TimeSource

References time source - an entity that supplies local and UTC times. The concrete implementation may elect to get accurate times from the network or other external precision time sources (i.e. NASA atomic clock)

Declaration
public static ITimeSource TimeSource { get; }
Property Value
Type Description
ITimeSource

Methods

LocalizedTimeToUniversalTime(DateTime)

Converts localized time to universal time as of TimeLocation property

Declaration
public static DateTime LocalizedTimeToUniversalTime(DateTime local)
Parameters
Type Name Description
System.DateTime local
Returns
Type Description
System.DateTime

SetMemoryModel(App.MemoryUtilizationModel)

Sets the memory utilization model for the whole app. This setting is NOT configurable. It may be set at process entrypoint via a call to App.SetMemoryModel() before the app contrainer spawns. Typical applications should not change the defaults. Some system service providers may examine this property to allocate less cache and temp buffers in the memory-constrained environments

Declaration
public static void SetMemoryModel(App.MemoryUtilizationModel model)
Parameters
Type Name Description
App.MemoryUtilizationModel model

UniversalTimeToLocalizedTime(DateTime)

Converts universal time to local time as of TimeLocation property

Declaration
public static DateTime UniversalTimeToLocalizedTime(DateTime utc)
Parameters
Type Name Description
System.DateTime utc
Returns
Type Description
System.DateTime
Back to top Copyright © 2006-2018 Agnicore Inc
Generated by DocFX