Class ModelInfo

java.lang.Object
jadex.model.modelinfo.Startable
jadex.model.modelinfo.ModelInfo
All Implemented Interfaces:
IModelInfo

public class ModelInfo extends Startable implements IModelInfo
Public model information that is provided as result from component factories when a model is loaded.
  • Field Details

    • name

      protected String name
      The name.
    • packagename

      protected String packagename
      The package.
    • imports

      protected List<String> imports
      The imports.
    • allimports

      protected String[] allimports
      All imports (cached for speed).
    • report

      protected IErrorReport report
      The report.
    • filename

      protected String filename
      The filename.
    • type

      protected String type
      The type.
    • fullname

      protected String fullname
      The full name (cached for speed).
    • breakpoints

      protected String[] breakpoints
      The breakpoints.
    • rawmodel

      protected Object rawmodel
      The raw model.
    • featuremodels

      protected Map<Class<?>,Object> featuremodels
      The feature models.
  • Constructor Details

  • Method Details

    • getName

      public String getName()
      Get the name.
      Specified by:
      getName in interface IModelInfo
      Returns:
      The name.
    • getPackage

      public String getPackage()
      Get the package name.
      Specified by:
      getPackage in interface IModelInfo
      Returns:
      The package name.
    • getFullName

      public String getFullName()
      Get the full model name (package.name)
      Specified by:
      getFullName in interface IModelInfo
      Returns:
      The full name.
    • getImports

      public String[] getImports()
      Get the imports.
      Specified by:
      getImports in interface IModelInfo
      Returns:
      The imports.
    • getAllImports

      public String[] getAllImports()
      Get the imports including the package.
      Specified by:
      getAllImports in interface IModelInfo
      Returns:
      The imports.
    • addImport

      public void addImport(String imp)
      Add an import statement.
    • getReport

      public IErrorReport getReport()
      Get the report.
      Specified by:
      getReport in interface IModelInfo
      Returns:
      The report.
    • getType

      public String getType()
      Get the model type.
      Specified by:
      getType in interface IModelInfo
      Returns:
      The model type (kernel specific).
    • getFilename

      public String getFilename()
      Get the filename.
      Specified by:
      getFilename in interface IModelInfo
      Returns:
      The filename.
    • setName

      public void setName(String name)
      Set the name.
      Parameters:
      name - The name to set.
    • setPackage

      public void setPackage(String packagename)
      Set the packagename.
      Parameters:
      packagename - The packagename to set.
    • setReport

      public void setReport(IErrorReport report)
      Set the report.
      Parameters:
      report - The report to set.
    • setImports

      public void setImports(String[] imports)
      Set the imports.
      Parameters:
      imports - The imports to set.
    • setFilename

      public void setFilename(String filename)
      Set the filename.
      Parameters:
      filename - The filename to set.
    • setType

      public void setType(String type)
      Set the component type.
      Parameters:
      type - The component type to set.
    • getBreakpoints

      public String[] getBreakpoints()
      Get the possible breakpoint places in that model.
      Specified by:
      getBreakpoints in interface IModelInfo
      Returns:
      The breakpoints.
    • setBreakpoints

      public void setBreakpoints(String[] breakpoints)
      Set the breakpoints.
      Parameters:
      breakpoints - The breakpoints to set.
    • checkName

      public boolean checkName()
      Check if the specified name matches the file name.
    • checkPackage

      public boolean checkPackage()
      Check if the specified package matches the file name.
    • getRawModel

      public Object getRawModel()
      Get the kernel-specific model.
      Specified by:
      getRawModel in interface IModelInfo
      Returns:
      The kernel-specific model when loaded locally, null for remote models.
    • internalSetRawModel

      public void internalSetRawModel(Object rawmodel)
      Set the kernel-specific model.
      Parameters:
      rawmodel - The kernel-specific model when loaded locally, null for remote models.
    • putFeatureModel

      public void putFeatureModel(Class<?> key, Object value)
      Put a new feature model in the map.
    • getFeatureModel

      public Object getFeatureModel(Class<?> key)
      Get a feature model per class.