Package eu.planets_project.tb.api.services

Examples of eu.planets_project.tb.api.services.ServiceTemplateRegistry


    /**
     * Sets the selected object's id and also fetches the object from the registry
     * @param sID
     */
    public void setSelectedServiceTemplate(String sID){
      ServiceTemplateRegistry registry = ServiceTemplateRegistryImpl.getInstance();
      this.selSerTemplate = registry.getServiceByID(sID);
    }
View Full Code Here


     * @return
     */
    public Map<String,String> getAllAvailableTBServiceTemplates(){
      Map<String,String> ret = new TreeMap<String,String>();
      ExperimentBean expBean = (ExperimentBean)JSFUtil.getManagedObject("ExperimentBean");
      ServiceTemplateRegistry registry = ServiceTemplateRegistryImpl.getInstance();
      Collection<TestbedServiceTemplate> templates = new Vector<TestbedServiceTemplate>();
     
      //determine which typeID has been selected
        //simple migration experiment
      if(expBean.getEtype().equals("experimentType.simpleMigration")){
        //mapping between service type ID and experiment type ID
        templates = registry.getAllServicesWithType(
            TestbedServiceTemplate.ServiceOperation.SERVICE_OPERATION_TYPE_MIGRATION
            );
      }
       //simple characterisation experiment
      if(expBean.getEtype().equals("experimentType.simpleCharacterisation")){
        templates = registry.getAllServicesWithType(
            TestbedServiceTemplate.ServiceOperation.SERVICE_OPERATION_TYPE_CHARACTERISATION
            );
      }
      //test if at least one template exists
      if((templates!=null)&&(templates.size()>0)){
View Full Code Here

     * by using the corresponding EvaluationServiceTemplate
     * @return Map<BenchmarkGoalID, EvaluationTestbedServiceTemplateImpl>
     */
    public Map<String, TestbedServiceTemplate> getSupportedAutoEvaluationBMGoals(){
      Map<String, TestbedServiceTemplate> ret = new HashMap<String, TestbedServiceTemplate>();
      ServiceTemplateRegistry registry = ServiceTemplateRegistryImpl.getInstance();
      Collection<TestbedServiceTemplate> evalSerTemplates = registry.getAllServicesWithType(TestbedServiceTemplate.ServiceOperation.SERVICE_OPERATION_TYPE_EVALUATION);
      if((evalSerTemplates!=null)&&(evalSerTemplates.size()>0)){
        Iterator<TestbedServiceTemplate> itTemplates = evalSerTemplates.iterator();
        //The template which registeres the BMGoal mapping
        EvaluationTestbedServiceTemplateImpl evalSerTemplate = (EvaluationTestbedServiceTemplateImpl) itTemplates.next();
       
View Full Code Here

   
    /**
     * Queries the ServiceTemplateRegistry and fills up the tree's root node with this data
     */
    public void loadTreeDataFromServiceTemplateRegistry(){
      ServiceTemplateRegistry registry = ServiceTemplateRegistryImpl.getInstance();
      Collection<TestbedServiceTemplate> templates = registry.getAllServices();
      //now call the init to build the tree model
      loadTreeData(templates);
    }
View Full Code Here

TOP

Related Classes of eu.planets_project.tb.api.services.ServiceTemplateRegistry

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.