org.iids.aos.locationmanager.negotiationmodule
Class AgentScapeDCTemplateManagement

java.lang.Object
  extended by org.iids.aos.systemservices.module.AbstractModule
      extended by org.iids.aos.systemservices.module.AbstractRunnableModule
          extended by org.iids.aos.locationmanager.negotiationmodule.AgentScapeDCTemplateManagement
All Implemented Interfaces:
java.lang.Runnable, Module

public class AgentScapeDCTemplateManagement
extends AbstractRunnableModule


Constructor Summary
AgentScapeDCTemplateManagement(AgentScapeDCNegotiationModule parent, Communicator comm)
           
 
Method Summary
 Template getDomainTemplate()
           
 java.lang.String getHMname(java.lang.String templateName)
           
 java.util.Collection<Template> getHostTemplates()
           
 java.util.Vector<Template> getMatchingTemplates(AgreementOffer leaseRequest)
           
 AgentScapeDCNegotiationModule getParent()
           
 TemplateList getTemplates()
           
 void pulse()
           
 void shutdown()
          Each abstract RUNNABLE module implementation must implement the shutdown method, which is called whenever the module is stopped (by AbstractRunnableModule.stop()) from the superclass.
 void updateDomainTemplate()
          This method creates a new domain template based on the templates received by the hosts.
 void updateTemplates(java.lang.Object[] HMs)
           
 void updateTemplates(java.lang.String HMname)
           
 
Methods inherited from class org.iids.aos.systemservices.module.AbstractRunnableModule
isStarted, run, start, stop
 
Methods inherited from class org.iids.aos.systemservices.module.AbstractModule
getCommunicator, getModuleName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AgentScapeDCTemplateManagement

public AgentScapeDCTemplateManagement(AgentScapeDCNegotiationModule parent,
                                      Communicator comm)
Method Detail

getParent

public AgentScapeDCNegotiationModule getParent()

getTemplates

public TemplateList getTemplates()
                          throws TemplateManagementException
Throws:
TemplateManagementException

pulse

public void pulse()
Specified by:
pulse in class AbstractRunnableModule

shutdown

public void shutdown()
Description copied from class: AbstractRunnableModule
Each abstract RUNNABLE module implementation must implement the shutdown method, which is called whenever the module is stopped (by AbstractRunnableModule.stop()) from the superclass.

Specified by:
shutdown in class AbstractRunnableModule

updateTemplates

public void updateTemplates(java.lang.String HMname)

updateTemplates

public void updateTemplates(java.lang.Object[] HMs)

getHMname

public java.lang.String getHMname(java.lang.String templateName)
                           throws java.lang.Exception
Throws:
java.lang.Exception

getDomainTemplate

public Template getDomainTemplate()

getHostTemplates

public java.util.Collection<Template> getHostTemplates()

getMatchingTemplates

public java.util.Vector<Template> getMatchingTemplates(AgreementOffer leaseRequest)
                                                throws TemplateManagementException
Throws:
TemplateManagementException

updateDomainTemplate

public void updateDomainTemplate()
This method creates a new domain template based on the templates received by the hosts. For each host-template, the creation constraints are retrieved, and added to the domain template. Currently three types of restrictionmodels are recognized: enumeration, min_value, and max_value. If creationconstraints of different templates overlap, some simple logic is used to combine the constraints: Enumeration: enumeration values of constraints are added to each other. MAX value: largest of max values is selected as creation constraint. MIN value: smallest of the min values is selected.



Copyright ? 2003, 2004 IIDS Group. All Rights Reserved.