|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ProgrammingLanguage
This interface states the functionality of a programming language processor
| Field Summary | |
|---|---|
static String |
ROLE
|
| Method Summary | |
|---|---|
CodeFormatter |
getCodeFormatter()
Return the CodeFormatter associated with this programming
language |
String |
getLanguageName()
Get Language Name |
String |
getSourceExtension()
Return the programming language's source file extension |
CompiledComponent |
instantiate(Program program)
Create a new instance for the given program type |
Program |
load(String filename,
File baseDirectory,
String encoding)
Load a program from a file |
Program |
preload(String filename,
File baseDirectory,
String encoding)
Preload a program from a file |
String |
quoteString(String constant)
Escape a String according to the programming language's
string constant encoding rules. |
void |
setLanguageName(String name)
Set Language Name |
void |
unload(Object program,
String filename,
File baseDirectory)
Unload from memory and invalidate a given program |
| Field Detail |
|---|
static final String ROLE
| Method Detail |
|---|
String getSourceExtension()
Program preload(String filename,
File baseDirectory,
String encoding)
throws LanguageException
filename - The program base file namebaseDirectory - The directory containing the program fileencoding - The encoding expected in the source file or
null if it is the platform's default encoding
LanguageException - If an error occurs during loading
Program load(String filename,
File baseDirectory,
String encoding)
throws LanguageException
filename - The program base file namebaseDirectory - The directory containing the program fileencoding - The encoding expected in the source file or
null if it is the platform's default encoding
LanguageException - If an error occurs during loading
CompiledComponent instantiate(Program program)
throws LanguageException
program - The program type
LanguageException - If an instantiation error occurs
void unload(Object program,
String filename,
File baseDirectory)
throws LanguageException
program - The programfilename - The name of the file this program was loaded frombaseDirectory - The directory containing the program file
LanguageException - If an error occursCodeFormatter getCodeFormatter()
CodeFormatter associated with this programming
language
null if none is
availableString quoteString(String constant)
String according to the programming language's
string constant encoding rules.
constant - The string to be escaped
void setLanguageName(String name)
name - The name of the languageString getLanguageName()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||