public class LQMServiceManager extends Object
| Constructor and Description |
|---|
LQMServiceManager(String[] args)
Create an instance, storing command-line arguments
|
| Modifier and Type | Method and Description |
|---|---|
static FileWriter |
fileWriter(String path)
Open a file for writing.
|
static <T> T |
get(Class<T> cl)
Retrieve any service by class
|
static LogicalModelFormat |
getFormat(String name)
Get the format declaration for a given ID.
|
static Iterable<LogicalModelFormat> |
getFormats()
Get the available formats.
|
static ModelModifierService |
getModifier(String name)
Get the service for a given ID.
|
static Iterable<ModelModifierService> |
getModifiers()
Get the available model modifier services.
|
static ModelToolService |
getTool(String name)
Get the tool declaration for a given ID.
|
static Iterable<ModelToolService> |
getTools()
Get the available tools.
|
static LogicalModel |
load(String filename)
Load a model guessing the format.
|
static LogicalModel |
load(String filename,
String format)
Load a model from file.
|
static LogicalModel |
modify(LogicalModel model,
String name)
Construct a modified model.
|
static LogicalModel |
modify(LogicalModel model,
String name,
String parameters)
Construct a modified model.
|
static boolean |
register(Service srv)
Register a service after initial service discovery.
|
static boolean |
save(LogicalModel model,
String filename,
String format)
Save a model to file
|
public final String[] args
public LQMServiceManager(String[] args)
args - the list of command-line arguments for use in scriptspublic static LogicalModelFormat getFormat(String name)
name - ID of the formatpublic static Iterable<LogicalModelFormat> getFormats()
public static ModelToolService getTool(String name)
name - ID of the toolpublic static Iterable<ModelToolService> getTools()
public static ModelModifierService getModifier(String name)
name - ID of the servicepublic static <T> T get(Class<T> cl)
T - the type of the desired servicecl - the class of the desired servicepublic static Iterable<ModelModifierService> getModifiers()
public static boolean register(Service srv)
srv - the new service to registerpublic static LogicalModel load(String filename)
filename - the path to the file to load (extension gives the format)public static LogicalModel modify(LogicalModel model, String name) throws Exception
model - the original modelname - the name of a modifierException - in case of error (following the Task interfce)modify(LogicalModel,String,String)public static LogicalModel modify(LogicalModel model, String name, String parameters) throws Exception
model - the original modelname - the name of a modifierparameters - parameters for the model modifierException - in case of error (following the Task interfce)ModelModifierService.modify(LogicalModel,String)public static FileWriter fileWriter(String path) throws IOException
path - the path to the file to openIOException - if it could not be createdpublic static LogicalModel load(String filename, String format)
filename - the path to the loaded fileformat - the name of the import formatpublic static boolean save(LogicalModel model, String filename, String format)
model - the model to savefilename - the path of the output fileformat - the name of the export formatCopyright © 2012–2020. All rights reserved.