Class PackageInfo
- java.lang.Object
-
- ru.ispras.microtesk.translator.codegen.PackageInfo
-
public final class PackageInfo extends java.lang.Object
ThePackageInfo
class holds information on package structure and names of generated Java classes.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
COMMON_TEMPLATE_DIR
Path to the folder that stores common templates (building blocks) to be reused in other templates.static java.lang.String
DEFAULT_OUTDIR
The root folder for generated models.static java.lang.String
JAVA_EXT
Extension for Java-files.static java.lang.String
MODE_CLASS_FORMAT
Format string for the name of the class of a particular mode (nML).static java.lang.String
MODE_PACKAGE_FORMAT
Format string for the name of the package that stores modes (nML).static java.lang.String
MODEL_PACKAGE
The name of the root package for generated models.static java.lang.String
MODEL_PACKAGE_FORMAT
Format string for the package where the specified model is located.static java.lang.String
NML_TEMPLATE_DIR
Path to the folder that stores string templates (building blocks) for generating model classes based on nML specifications.static java.lang.String
OP_CLASS_FORMAT
Format string for the name of the class of a particular op (nML).static java.lang.String
OP_PACKAGE_FORMAT
Format string for the name of the package that stores ops (nML).static java.lang.String
SHARED_CLASS_FORMAT
Format string for the name of the class that holds information on the microprocessor state and other global data (context).static java.lang.String
SHARED_PACKAGE_FORMAT
Format string for the name of the package where we store information on the microprocessor state and other global data (context).
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.String
getModeFileFormat(java.lang.String outDir)
Format string for the file name of the class of a particular mode (nML).static java.lang.String
getModeFileFormat(java.lang.String outDir, java.lang.String ext)
static java.lang.String
getModelFileFormat(java.lang.String outDir)
Format string for the main class file of the specified model.static java.lang.String
getModelOutDir(java.lang.String outDir)
The folder where the root package for generated models is located.static java.lang.String
getOpFileFormat(java.lang.String outDir)
Format string for the file name of the class of a particular op (nML).static java.lang.String
getOpFileFormat(java.lang.String outDir, java.lang.String ext)
static java.lang.String
getSharedFileFormat(java.lang.String outDir)
Format string for the name of the class file that holds information on the microprocessor state and other global data (context).static java.lang.String
getSharedFileFormat(java.lang.String outDir, java.lang.String ext)
-
-
-
Field Detail
-
JAVA_EXT
public static final java.lang.String JAVA_EXT
Extension for Java-files.- See Also:
- Constant Field Values
-
COMMON_TEMPLATE_DIR
public static final java.lang.String COMMON_TEMPLATE_DIR
Path to the folder that stores common templates (building blocks) to be reused in other templates.- See Also:
- Constant Field Values
-
NML_TEMPLATE_DIR
public static final java.lang.String NML_TEMPLATE_DIR
Path to the folder that stores string templates (building blocks) for generating model classes based on nML specifications.- See Also:
- Constant Field Values
-
DEFAULT_OUTDIR
public static final java.lang.String DEFAULT_OUTDIR
The root folder for generated models.- See Also:
- Constant Field Values
-
MODEL_PACKAGE
public static final java.lang.String MODEL_PACKAGE
The name of the root package for generated models.- See Also:
- Constant Field Values
-
MODEL_PACKAGE_FORMAT
public static final java.lang.String MODEL_PACKAGE_FORMAT
Format string for the package where the specified model is located. Format parameters: model name.- See Also:
- Constant Field Values
-
SHARED_PACKAGE_FORMAT
public static final java.lang.String SHARED_PACKAGE_FORMAT
Format string for the name of the package where we store information on the microprocessor state and other global data (context). Format parameters: model name.- See Also:
- Constant Field Values
-
SHARED_CLASS_FORMAT
public static final java.lang.String SHARED_CLASS_FORMAT
Format string for the name of the class that holds information on the microprocessor state and other global data (context). Format parameters: model name.- See Also:
- Constant Field Values
-
MODE_PACKAGE_FORMAT
public static final java.lang.String MODE_PACKAGE_FORMAT
Format string for the name of the package that stores modes (nML). Format parameters: model name.- See Also:
- Constant Field Values
-
MODE_CLASS_FORMAT
public static final java.lang.String MODE_CLASS_FORMAT
Format string for the name of the class of a particular mode (nML). Format parameters: model name, mode name.- See Also:
- Constant Field Values
-
OP_PACKAGE_FORMAT
public static final java.lang.String OP_PACKAGE_FORMAT
Format string for the name of the package that stores ops (nML). Format parameters: model name.- See Also:
- Constant Field Values
-
OP_CLASS_FORMAT
public static final java.lang.String OP_CLASS_FORMAT
Format string for the name of the class of a particular op (nML). Format parameters: model name, op name.- See Also:
- Constant Field Values
-
-
Method Detail
-
getModelOutDir
public static final java.lang.String getModelOutDir(java.lang.String outDir)
The folder where the root package for generated models is located.- Parameters:
outDir
- Output directory path.- Returns:
- Model directory path.
-
getModelFileFormat
public static java.lang.String getModelFileFormat(java.lang.String outDir)
Format string for the main class file of the specified model. Format parameters: model name.- Parameters:
outDir
- Output directory path.- Returns:
- Model source file path format.
-
getSharedFileFormat
public static java.lang.String getSharedFileFormat(java.lang.String outDir)
Format string for the name of the class file that holds information on the microprocessor state and other global data (context). Format parameters: model name.- Parameters:
outDir
- Output directory path.- Returns:
- Shared source file path format.
-
getSharedFileFormat
public static java.lang.String getSharedFileFormat(java.lang.String outDir, java.lang.String ext)
-
getModeFileFormat
public static java.lang.String getModeFileFormat(java.lang.String outDir)
Format string for the file name of the class of a particular mode (nML). Format parameters: model name, mode name.- Parameters:
outDir
- Output directory path.- Returns:
- Addressing mode source file path format.
-
getModeFileFormat
public static java.lang.String getModeFileFormat(java.lang.String outDir, java.lang.String ext)
-
getOpFileFormat
public static java.lang.String getOpFileFormat(java.lang.String outDir)
Format string for the file name of the class of a particular op (nML). Format parameters: model name, op name.- Parameters:
outDir
- Output directory path.- Returns:
- Operation source file path format.
-
getOpFileFormat
public static java.lang.String getOpFileFormat(java.lang.String outDir, java.lang.String ext)
-
-