Class ArchitectureModelRepositoryFactory
java.lang.Object
kieker.analysis.architecture.repository.ArchitectureModelRepositoryFactory
public final class ArchitectureModelRepositoryFactory
extends java.lang.Object
Create, load and store architecture and utility models.
- Since:
- 2.0.0
- Author:
- Reiner Jung
-
Field Summary
Fields Modifier and Type Field Description static ModelDescriptor
ASSEMBLY_MODEL_DESCRIPTOR
Model descriptor for the assembly model.static java.lang.String
ASSEMBLY_MODEL_NAME
Standard assembly model file name.static ModelDescriptor
DEPLOYMENT_MODEL_DESCRIPTOR
Model descriptor for the deployment model.static java.lang.String
DEPLOYMENT_MODEL_NAME
Standard deployment model file name.static ModelDescriptor
EXECUTION_MODEL_DESCRIPTOR
Model descriptor for the execution model.static java.lang.String
EXECUTION_MODEL_NAME
Standard execution model file name.static ModelDescriptor
SOURCE_MODEL_DESCRIPTOR
Model descriptor for the source model.static java.lang.String
SOURCE_MODEL_NAME
Standard source model file name.static ModelDescriptor
STATISTICS_MODEL_DESCRIPTOR
Model descriptor for the statistics model.static java.lang.String
STATISTICS_MODEL_NAME
Standard statistics model file name.static ModelDescriptor
TYPE_MODEL_DESCRIPTOR
Model descriptor for the type model.static java.lang.String
TYPE_MODEL_NAME
Standard type model file name. -
Method Summary
Modifier and Type Method Description static ModelRepository
createEmptyModelRepository(java.lang.String repositoryName)
Create an empty repository for architecture models.static ModelRepository
createModelRepository(java.lang.String repositoryName, ModelDescriptor... descriptors)
Create a model repository with a set of empty models.static ModelRepository
readModelRepository(java.nio.file.Path inputDirectory, ModelDescriptor... descriptors)
Read a set of model files into a model repository.static void
writeModelRepository(java.nio.file.Path outputDirectory, ModelRepository repository)
Write a model repository to the file system.
-
Field Details
-
TYPE_MODEL_NAME
public static final java.lang.String TYPE_MODEL_NAMEStandard type model file name.- See Also:
- Constant Field Values
-
ASSEMBLY_MODEL_NAME
public static final java.lang.String ASSEMBLY_MODEL_NAMEStandard assembly model file name.- See Also:
- Constant Field Values
-
DEPLOYMENT_MODEL_NAME
public static final java.lang.String DEPLOYMENT_MODEL_NAMEStandard deployment model file name.- See Also:
- Constant Field Values
-
EXECUTION_MODEL_NAME
public static final java.lang.String EXECUTION_MODEL_NAMEStandard execution model file name.- See Also:
- Constant Field Values
-
STATISTICS_MODEL_NAME
public static final java.lang.String STATISTICS_MODEL_NAMEStandard statistics model file name.- See Also:
- Constant Field Values
-
SOURCE_MODEL_NAME
public static final java.lang.String SOURCE_MODEL_NAMEStandard source model file name.- See Also:
- Constant Field Values
-
TYPE_MODEL_DESCRIPTOR
Model descriptor for the type model. -
ASSEMBLY_MODEL_DESCRIPTOR
Model descriptor for the assembly model. -
DEPLOYMENT_MODEL_DESCRIPTOR
Model descriptor for the deployment model. -
EXECUTION_MODEL_DESCRIPTOR
Model descriptor for the execution model. -
STATISTICS_MODEL_DESCRIPTOR
Model descriptor for the statistics model. (optional) -
SOURCE_MODEL_DESCRIPTOR
Model descriptor for the source model. (optional)
-
-
Method Details
-
createEmptyModelRepository
Create an empty repository for architecture models.- Parameters:
repositoryName
- name of the repository- Returns:
- a new instance of an empty repository
-
createModelRepository
public static ModelRepository createModelRepository(java.lang.String repositoryName, ModelDescriptor... descriptors)Create a model repository with a set of empty models.- Parameters:
repositoryName
- name of the repositorydescriptors
- list of model descriptors- Returns:
- returns on success an model repository with a set of empty models
-
readModelRepository
public static ModelRepository readModelRepository(java.nio.file.Path inputDirectory, ModelDescriptor... descriptors) throws ConfigurationExceptionRead a set of model files into a model repository.- Parameters:
inputDirectory
- the directory containing all model filesdescriptors
- list of model descriptors defining which models to read- Returns:
- returns on success a complete model repository
- Throws:
ConfigurationException
- on errors
-
writeModelRepository
public static void writeModelRepository(java.nio.file.Path outputDirectory, ModelRepository repository) throws java.io.IOExceptionWrite a model repository to the file system. The output directory is created in case it does not exist.- Parameters:
outputDirectory
- output directory for all model filesrepository
- the model repository to be stored- Throws:
java.io.IOException
- on write errors
-