ArcFM Responder Mobile Developer Guide
Services Property






Gets the ServiceContainer for the Responder applications.
Syntax
'Declaration
 
Public Shared ReadOnly Property Services As System.ComponentModel.Design.IServiceContainer
'Usage
 
Dim value As System.ComponentModel.Design.IServiceContainer
 
value = RxApp.Services
public static System.ComponentModel.Design.IServiceContainer Services {get;}
public read-only property Services: System.ComponentModel.Design.IServiceContainer; static; 
public static function get Services : System.ComponentModel.Design.IServiceContainer
public: __property static System.ComponentModel.Design.IServiceContainer* get_Services();
public:
static property System.ComponentModel.Design.IServiceContainer^ Services {
   System.ComponentModel.Design.IServiceContainer^ get();
}

Property Value

The services.
Remarks

For 9.2sp3 and earlier, the object references in RxApp.Services were shared across threads (i.e., standard System.ComponentModel.Design.ServiceContainer behavior). This was "good-enough" at the time because all calls to IDataServices (via our MSMQ remoting channel) were processed on a single STA thread. A call to RxApp.Services.GetService from a SubmitRule or DataRequest object was already on the "correct" thread - however, it was possible to spawn a new thread and access the "shared" instance from another thread which would inadvertently require marshaling.

In order to support multi-threading and support working with COM objects the behavior of the RxApp.Services service container has changed. That is, in order to be multi-threaded it needs to support multiple COM STA apartments (which means that COM object instances cannot be shared across multiple threads, but rather requires an instance per-thread). For non-COM types the service container works as before (shared across all threads); however, for COM service types (e.g. IWorkspace) the service will be per-thread. Also, in order to prevent (and expose) inadvertent marshaling issues the new ComAwareServiceContainer will throw an exception if an MTA thread attempts to access a COM service type.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

RxApp Class
RxApp Members

Send Feedback