|
Agents can often represent Organizations. The In order to use Relationships, you must first do the following: 1. Add the plugin = org.cougaar.mlm.plugin.organization.OrgRTDataPlugin entry to the Agent configuration file. 2. Add the plugin = org.cougaar.mlm.plugin.organization.OrgReportPlugin entry to the Agent configuration file. If these plugins are left out, no Organization Assets will appear on the Agent's blackboard. 3. The glm Domain should be added to the Node. Do in the LDMDomain.ini file add: glm=org.cougaar.glm.ldm.GLMDomain At this point you are ready to make use of the prototype-ini.dat file. Lets take an example of two agents: StoreAgent and PaymentAgent. The PaymentAgent agent provides the role of "PaymentAuthority" for the store. So it makes sense for the PaymentAgent to have the role of "PaymentAuthority". This is how PaymentAgent's prototype-ini.dat file might look: |
|
[Prototype] Organization [UniqueId] "UTC/CivilianOrg" [UIC] "UIC/PaymentAgent" [Relationship] Supporting "StoreAgent" "PaymentAuthority" [TypeIdentificationPG] TypeIdentification String "UTC/RTOrg" Nomenclature String "PaymentAgent" AlternateTypeIdentification String "SRC/PaymentAgent" [ClusterPG] MessageAddress MessageAddress "PaymentAgent" [OrganizationPG] Roles Collection |
|
Here is a line by line description of the above example: 1. [Prototype] Organization This line identifies the Asset to be prototyped. In this case, the Organization Asset. 2. [UniqueId] "UTC/CivilianOrg" 3. [Relationship] This line identifies that the following portion of the file identifies Relationships 4. Supporting "StoreAgent" "PaymentAuthority" This line identifies a Supporting relationship where PaymentAuthority supports StoreAgent. 5. [TypeIdentificationPG] This line idenifies the following lines as attributes of the TypeIdentificationPG of the Organization Asset 6. TypeIdentification String "UTC/RTOrg" Fills the TypeIdentification Attribute of the TypeIdentificationPG 7. Nomenclature String "PaymentAgent" Fills the Nomenclature Attribute of the TypeIdentificationPG 8. AlternateTypeIdentification String "SRC/PaymentAgent" Fills the AlternateTypeIdentification attribute of the TypeIdentificationPG 9. [ClusterPG] This line identifies the following lines as attributes of the ClusterPG of the Organization Asset 10. MessageAddress MessageAddress "PaymentAgent" Fills the MessageAddress attribute of the ClusterPG. This should have the value of the Agent's MessageAddress. 11.[OrganizationPG] This line identifies the following lines as attributes of the OrganizationPG of the Organization Asset 12.Roles Collection Having a basic overview of how to create agent relationships, the next step is to learn how to use XML to create Assets and prototypes. |