public interface RepositoryFacade
AndroMDA does code generation from an object model. There must exist a repository in which the model can be loaded. The repository must be able to load the object model given a URL. Any repository that supports this API can be used by AndroMDA.
Modifier and Type | Method and Description |
---|---|
void |
clear()
Clears the repository of any model(s)
(without shutting it down).
|
void |
close()
Closes the repository and reclaims all resources.
|
ModelAccessFacade |
getModel()
Returns the facade as the given
type for the top-level model object from the repository. |
void |
open()
Opens and initialize the repository.
|
void |
readModel(InputStream[] streams,
String[] uris,
String[] moduleSearchPath)
Reads the object model into the repository from the given model streams.
|
void |
readModel(String[] uris,
String[] moduleSearchPath)
Reads the object model into the repository from one or more model URIs.
|
void |
writeModel(Object model,
String outputLocation,
String version)
Writes the given
model to the specified outputLocation using the default encoding
provided by the model writer. |
void |
writeModel(Object model,
String outputLocation,
String version,
String encoding)
Writes the given
model to the specified outputLocation . |
void open()
void close()
void readModel(String[] uris, String[] moduleSearchPath)
Reads the object model into the repository from one or more model URIs. If uris is
null or zero length, then an empty model will be created in the repository
and can be retrieved from getModel()
.
uris
- a list of modelUrls from which to load each URL of the model.moduleSearchPath
- a list of paths from which to search for module models (i.e. models that can be referenced from
within other models).void readModel(InputStream[] streams, String[] uris, String[] moduleSearchPath)
getModel()
.streams
- a list of InputStream instances containing a model.uris
- a list of URIs from which each stream in the streams
parameter was loaded (note that the size
and order of this list must match the order of the streams list).moduleSearchPath
- a list of paths from which to search for module models (i.e. models that can be referenced from
within other models).void writeModel(Object model, String outputLocation, String version, String encoding)
model
to the specified outputLocation
.model
- the model
to write.outputLocation
- the location to write the model file.version
- the version
of the model to be written (i.e. could be XMI version if the
repository writes XMI files).encoding
- the encoding of the file to be written.void writeModel(Object model, String outputLocation, String version)
model
to the specified outputLocation
using the default encoding
provided by the model writer.model
- the model
to write.outputLocation
- the location to write the model file.version
- the version
of the model to be written (i.e. could be XMI version if the
repository writes XMI files).ModelAccessFacade getModel()
type
for the top-level model object from the repository. This model object
contains all models read
into the repository. If the type is not specified, the default model access
facade will be used.null
if no models exist in the repository).void clear()
Copyright © 2003–2014 AndroMDA.org. All rights reserved.