Class ApplicationTemplate

java.lang.Object
com.aquima.interactions.test.templates.AbstractReportingTemplate
com.aquima.interactions.test.templates.ApplicationTemplate
All Implemented Interfaces:
IApplicationTemplate

public class ApplicationTemplate extends AbstractReportingTemplate implements IApplicationTemplate
This class may be used to quickly initialize a model.
Since:
6.0
Author:
O. Kerpershoek
  • Constructor Details

    • ApplicationTemplate

      public ApplicationTemplate()
      Construct an application template with name "test-app".
    • ApplicationTemplate

      public ApplicationTemplate(String name)
      Construct an application template with a specific name.
      Parameters:
      name - Name of the application template.
    • ApplicationTemplate

      public ApplicationTemplate(String name, String branchName)
      Construct an application template with a specific name.
      Parameters:
      name - Name of the application template.
      branchName - Name of the branch that is used in the application id.
      Since:
      9.0
    • ApplicationTemplate

      public ApplicationTemplate(String name, com.aquima.interactions.foundation.Version version)
      Construct an application template with a specific name.
      Parameters:
      name - Name of the application template.
      version - The version of the application
      Since:
      9.0
  • Method Details

    • createReport

      protected static com.aquima.interactions.foundation.report.IInitializationReport createReport(String appName)
    • addModule

      public ApplicationTemplate addModule(String moduleName)
    • getCommunicationEngine

      public CommunicationEngineTemplate getCommunicationEngine()
      This method returns the communication definitions.
      Returns:
      The communication definitions
    • getSpellEngine

      public SpellEngineTemplate getSpellEngine()
      This method returns the spell engine.
      Returns:
      The spell engine
    • getTimer

      public TimerTemplate getTimer()
      This method returns the timer.
      Returns:
      The timer template, never null.
    • getUserScopeDao

      public com.aquima.interactions.userscope.dao.IUserScopeDao getUserScopeDao()
      This method returns the user scope dao.
      Returns:
      The user scope dao, never null.
    • getName

      public String getName()
      This method returns the name of the application.
      Returns:
      the name of the application.
    • setLicenseKey

      public void setLicenseKey(String key)
      This method sets a license key to be user for the testcases.
      Parameters:
      key - The license key to use.
    • getLicenseKey

      public String getLicenseKey()
      This method returns a test case license.
      Returns:
      License key
    • getApplicationId

      public com.aquima.interactions.foundation.ApplicationID getApplicationId()
      This method returns the ID of the application.
      Specified by:
      getApplicationId in interface IApplicationTemplate
      Returns:
      the ID of the application.
    • getModuleId

      public com.aquima.interactions.project.ModuleID getModuleId()
      This method returns the ID of the main module.
      Returns:
      The ID of the main module.
    • getFactoryManager

      public FactoryManagerTemplate getFactoryManager()
      This method returns the factory manager of the application.
      Specified by:
      getFactoryManager in interface IApplicationTemplate
      Returns:
      the factory manager of the application.
    • getFlowEngine

      public FlowEngineTemplate getFlowEngine()
      This method returns the flow engine of the application.
      Returns:
      the flow engine of the application.
    • getMetaModel

      public MetaModelTemplate getMetaModel()
      This method returns the meta model of the application.
      Returns:
      the meta model of the application.
    • getRuleEngine

      public RuleEngineTemplate getRuleEngine()
      This method returns the rule engine of the application.
      Returns:
      the rule engine of the application.
    • getTreeEngine

      public TreeEngineTemplate getTreeEngine()
      This method returns the tree engine of the application.
      Returns:
      the tree engine of the application.
    • getMatchEngine

      public MatchEngineTemplate getMatchEngine()
      This method returns the match engine of the application.
      Returns:
      the match engine of the application.
    • getProcessEngine

      public ProcessEngineTemplate getProcessEngine()
      This method returns the process engine (template) of the application.
      Returns:
      the process engine (template) of the application.
    • getConfiguration

      public ConfigurationTemplate getConfiguration()
      This method returns the configuration of the application.
      Specified by:
      getConfiguration in interface IApplicationTemplate
      Returns:
      the configuration of the application.
    • getReport

      public com.aquima.interactions.foundation.report.IInitializationReport getReport()
      This method returns the initialization report for the application.
      Specified by:
      getReport in interface IApplicationTemplate
      Returns:
      the initialization report for the application.
    • getLicenseProvider

      public com.aquima.interactions.foundation.ILicenseProvider getLicenseProvider()
      This method returns the license provider for the test application.
      Specified by:
      getLicenseProvider in interface IApplicationTemplate
      Returns:
      the license provider for the test application.
    • setPortalMessageBus

      public void setPortalMessageBus(com.aquima.interactions.portal.IPortalMessageBus messageBus)
    • getPortalMessageBus

      public com.aquima.interactions.portal.IPortalMessageBus getPortalMessageBus()
      Description copied from interface: IApplicationTemplate
      This method returns the configured portal message bus for the test application.
      Specified by:
      getPortalMessageBus in interface IApplicationTemplate
      Returns:
    • addServiceCall

      public void addServiceCall(ServiceCallTemplate serviceCall)
      This method adds a service call.
      Parameters:
      serviceCall - The service call to add.
    • addServiceCall

      public ServiceCallTemplate addServiceCall(String serviceCallName, String serviceTypeName)
      This method creates and adds a service call.
      Parameters:
      serviceCallName - The service call name.
      serviceTypeName - The service type name.
      Returns:
      The created service call.
    • addFunctionCall

      public FunctionCallTemplate addFunctionCall(String functionCallName, String moduleName, String flowName)
    • addFunctionCall

      public void addFunctionCall(FunctionCallTemplate functionCall)
      This method adds a function call.
      Parameters:
      functionCall - The function call to add.
    • addMaskCall

      public void addMaskCall(MaskCallTemplate maskCall)
      This method adds a mask call.
      Parameters:
      maskCall - The mask call to add.
    • getServiceCalls

      protected Iterator<ServiceCallTemplate> getServiceCalls()
    • getFunctionCalls

      protected Iterator<FunctionCallTemplate> getFunctionCalls()
    • getServiceCall

      public ServiceCallTemplate getServiceCall(String serviceCallName)
      This method returns the service call for a service call name.
      Parameters:
      serviceCallName - The service call name used for lookup (case insensitive)
      Returns:
      The service call, may be null
    • getFunctionCall

      public FunctionCallTemplate getFunctionCall(String functionCallName)
      This method returns the function call for a function call name.
      Parameters:
      functionCallName - The function call name used for lookup (case insensitive)
      Returns:
      The function call, may be null
    • getComposer

      public ComposerTemplate getComposer()
      This method returns the composer of the application.
      Returns:
      the composer of the application.
    • getMaskCalls

      protected Iterator<MaskCallTemplate> getMaskCalls()
    • getProcessMapping

      public ProcessMappingTemplate getProcessMapping()
      This method returns the process mapping that should be used. Process mappings are only relevant for applications that use a process engine.
      Returns:
      Template containing the process mappings that should be used.
    • getProject

      public ProjectTemplate getProject()
      This method returns the project template that may be used to add project wide definitions.
      Returns:
      The project template.
    • getProcessEngineManager

      public ProcessEngineManagerTemplate getProcessEngineManager()
      This method returns the process engine manager template. The process engine manager may be used to configure process modules.
      Returns:
      the process engine manager template.
    • toDataSource

      public com.aquima.interactions.portal.ds.IPortalEngineDS toDataSource()
      This method converts the application template to a data-source that can be used to initialize a portal engine.
      Specified by:
      toDataSource in interface IApplicationTemplate
      Returns:
      a data-source that can be used to initialize a portal engine.
    • toAppDataSource

      public com.aquima.interactions.portal.ds.IApplicationDS toAppDataSource()
      Description copied from interface: IApplicationTemplate
      This method converts the application template to a data-source that can be used to initialize an application.
      Specified by:
      toAppDataSource in interface IApplicationTemplate
      Returns:
      a data-source that can be used to initialize an application.
    • addMapping

      public MappingTemplate addMapping(String name, MetaModelTemplate sourceModel, MetaModelTemplate targetModel)
    • addMapping

      protected void addMapping(MappingTemplate mapping)
    • addWebService

      public WebServiceTemplate addWebService(String serviceName)
      This method adds an exposed webservice.
      Parameters:
      serviceName - The name of the exposed web service.
      Returns:
      The created template
    • addWebService

      public WebServiceTemplate addWebService(String serviceName, com.aquima.interactions.project.ModuleID moduleId)
      This method adds a service mapping.
      Parameters:
      serviceName - The name of the exposed web service.
      moduleId - The id of the module that contains the webservice, may be null.
      Returns:
      The created template
    • getMappings

      protected Iterator<MappingTemplate> getMappings()
    • getModules

      protected Iterator<ApplicationTemplate> getModules()
    • getWebServices

      protected Iterator<WebServiceTemplate> getWebServices()
    • getModule

      public ApplicationTemplate getModule(com.aquima.interactions.project.ModuleID moduleId)
    • getProcessEngineSettings

      public com.aquima.interactions.process.IProcessEngineSettings getProcessEngineSettings()
      Description copied from interface: IApplicationTemplate
      This method returns the configured process engine settings for the test process module
      Specified by:
      getProcessEngineSettings in interface IApplicationTemplate
      Returns:
    • getProjectMetadata

      public com.aquima.interactions.portal.ds.ProjectMetadata getProjectMetadata()
    • setProjectMetadata

      public void setProjectMetadata(com.aquima.interactions.portal.ds.ProjectMetadata projectMetadata)