Package cmion.level2

Class CompetencyLibrary


  • public class CompetencyLibrary
    extends CmionComponent
    the competency library is the component that registers all components
    • Constructor Summary

      Constructors 
      Constructor Description
      CompetencyLibrary​(IArchitecture architecture, java.lang.String competencyLibraryFile)
      Create a new competency library
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.ArrayList<Competency> getCompetencies​(java.lang.String type)
      return a List of competencies with the given type, the list will be empty if no such competency is in the library
      java.util.ArrayList<SamgarCompetencyInfo> getSamgarCompetencyInfos()
      returns a list of information items regarding the samgar competencies to be loaded by the architecture.
      protected java.io.InputStream openConfigurationFile​(java.lang.String competencyLibraryFile)  
      void registerHandlers()
      every cmion component has to implement this method and register its event and request handlers in here
      void startBackgroundCompetencies()
      in this function all competencies that are continuously running in the background are started
      • Methods inherited from class ion.Meta.Element

        destroy, getEventFilters, getEventHandlers, getRequestFilters, getRequestHandlers, getSimulation, getUID, schedule, wasDestroyed
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CompetencyLibrary

        public CompetencyLibrary​(IArchitecture architecture,
                                 java.lang.String competencyLibraryFile)
                          throws java.lang.Exception
        Create a new competency library
        Throws:
        java.lang.Exception
    • Method Detail

      • openConfigurationFile

        protected java.io.InputStream openConfigurationFile​(java.lang.String competencyLibraryFile)
                                                     throws java.lang.Exception
        Throws:
        java.lang.Exception
      • registerHandlers

        public final void registerHandlers()
        Description copied from class: CmionComponent
        every cmion component has to implement this method and register its event and request handlers in here
        Specified by:
        registerHandlers in class CmionComponent
      • startBackgroundCompetencies

        public void startBackgroundCompetencies()
        in this function all competencies that are continuously running in the background are started
      • getCompetencies

        public java.util.ArrayList<Competency> getCompetencies​(java.lang.String type)
        return a List of competencies with the given type, the list will be empty if no such competency is in the library
      • getSamgarCompetencyInfos

        public java.util.ArrayList<SamgarCompetencyInfo> getSamgarCompetencyInfos()
        returns a list of information items regarding the samgar competencies to be loaded by the architecture. Do not modify the returned list or its contents outside this method