Namespace: Consultingwerk.Framework
Class 
ServiceLoader Copy to Clipboard
Parent classes:
Inherits: Progress.Lang.Object

File:ServiceLoader
Purpose:Automates loading of services into the ServiceContainer
Description:Temp-Table Structure in Consultingwerk/Framework/ttServiceLoader.i
Author(s):Mike Fechner / Consultingwerk Ltd.
Created:Mon Nov 07 23:14:29 CET 2011
Notes:The ServiceTypeName field in the temp-table / xml document
may contain a comma-delimited list of interface/class names.
In that case a single service instance will be registered
using multiple interfaces
Sample XML structure:
<ttServiceLoader xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ttServiceLoaderRow>
<Order>1</Order>
<ServiceTypeName>Consultingwerk.Framework.IAuthenticationService</ServiceTypeName>
<ServiceClassName>Consultingwerk.SmartFramework.Authentication.AuthenticationService</ServiceClassName>
<Disabled>false</Disabled>
</ttServiceLoaderRow>
</ttServiceLoader>
Supports custom log file messages using the "ServiceLoader" custom message sub system



Top Method Summary
Options Name Purpose
+ Load (character) Loads and registers services from a XML file
+ Load (character, logical) Loads and registers services from a XML file
+ Load (handle) Loads and registers services from a temp-table
+ Load (handle, logical) Loads and registers services from a temp-table
+ LoadFromFile (character) Loads and registers services from an XML file
+ LoadFromFile (character, logical) Loads and registers services from an XML file

Top Constructor Summary
Options Name Purpose
+ ServiceLoader () Constructor for the ServiceLoader class
+ ServiceLoader (IServiceContainer) Constructor for the ServiceLoader class

Top Property Summary
Options Name Purpose
+ Consultingwerk.Framework.IServiceContainer ServiceContainer Returns the reference to the ServiceContainer used by this ServiceLoader


Method Detail
Top

PUBLIC Load (character)

Purpose: Loads and registers services from a XML file
Notes: Does not ignore duplicates (will error on duplicates)

Parameters:
pcFileName CHARACTER
An XML Document containing the service definitions
Top

PUBLIC Load (character, logical)

Purpose: Loads and registers services from a XML file
Notes:

Parameters:
pcFileName CHARACTER
An XML Document containing the service definitions
plIgnoreDuplicates LOGICAL
Logical flag indicating if duplicates (by service interface) will be ignored
Top

PUBLIC Load (handle)

Purpose: Loads and registers services from a temp-table
Notes: Does not ignore duplicates (will error on duplicates)

Parameters:
phTableHandle HANDLE
The handle to a temp-table containing the service definitions
Top

PUBLIC Load (handle, logical)

Purpose: Loads and registers services from a temp-table
Notes:

Parameters:
phTableHandle HANDLE
The handle to a temp-table containing the service definitions
plIgnoreDuplicates LOGICAL
Logical flag indicating if duplicates (by service interface) will be ignored
Top

PUBLIC LoadFromFile (character)

Purpose: Loads and registers services from an XML file
Notes: Does not ignore duplicates (will error on duplicates)

Parameters:
pcFileName CHARACTER
An XML Document containing the service definitions
Top

PUBLIC LoadFromFile (character, logical)

Purpose: Loads and registers services from an XML file
Notes:

Parameters:
pcFileName CHARACTER
An XML Document containing the service definitions
plIgnoreDuplicates LOGICAL
Logical flag indicating if duplicates (by service interface) will be ignored


Constructor Detail
Top

PUBLIC ServiceLoader ()

Purpose: Constructor for the ServiceLoader class
Notes: Uses FrameworkSettings:ServiceContainer as the default ServiceContainer

Top

PUBLIC ServiceLoader (IServiceContainer)

Purpose: Constructor for the ServiceLoader class
Notes:

Parameters:
poServiceContainer Consultingwerk.Framework.IServiceContainer
The ServiceContainer to work with


Property Detail
Top

PUBLIC Consultingwerk.Framework.IServiceContainer ServiceContainer

Purpose: Returns the reference to the ServiceContainer used by this ServiceLoader
Notes:

Returns Consultingwerk.Framework.IServiceContainer


©2006-2016 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       26.08.2016 08:29:03