[This is preliminary documentation and is subject to change.]

Initializes a MetaCognitiveModule of the specified type (to be placed in the MCS upon being committed)

Namespace: Clarion
Assembly: CLARIONLibrary (in CLARIONLibrary.dll) Version: 6.1.0.7 (6.1.0.7)

Syntax

C#
public static T InitializeMetaCognitiveModule<T>(
	Agent destination,
	IMetaCognitiveModuleFactory<T> factory,
	params Object[] parameters
)
where T : MetaCognitiveModule

Parameters

destination
Type: Clarion.Framework..::..Agent
The agent in whom the module is being attached
factory
Type: Clarion.Framework.Templates..::..IMetaCognitiveModuleFactory<(Of <(<'T>)>)>
The factory to use to generate the module
parameters
Type: array<System..::..Object>[]()[][]
(optional) Any parameters that may be needed by the factory in order to initialize the module.
To find-out the list of required and optional parameters, please consult the documentation of the factory for the module being generated

Type Parameters

T
The type of module that is to be initialized

Return Value

A module of the type specified initialized within the agent specified

Remarks

Caution
Don't forget that the module being initialized by this method MUST be committed to the agent in which it was initialized! Failure to do so WILL result in an error!

Examples

CopyC#
GoalSelectionModule gsm = AgentInitializer.InitializeMetaCognitiveModule(John, GoalSelectionModule.Factory);

BPNetwork comp = AgentInitializer.InitializeMetaCognitiveDecisionNetwork(gsm, BPNetwork.Factory);

//Elided code further initializing the module and network

gsm.Commit(comp);

John.Commit(gsm);

See Also