Package org.qbicc.machine.tool
Interface CCompilerInvoker
- All Superinterfaces:
MessagingToolInvoker,ToolInvoker
An invoker for a C compiler.
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptiondefault voidaddDefinedSymbol(String name) Define a symbol to the C compiler to "1".voidaddDefinedSymbol(String name, String value) Define a symbol to the C compiler.voidaddIncludePath(Path path) Add an include path.default voidaddIncludePaths(Iterable<Path> paths) Add all the given include paths.getDefinedSymbol(int index) Get the defined symbol at the given index.intGet the number of defined symbols.getDefinedSymbolValue(int index) Get the defined symbol value.getIncludePath(int index) Get the include path at the given index.intGet the number of include paths defined.Get the object file output path.Get the input source for the C program.voidsetOutputPath(Path path) Set the object file output path.voidsetSource(InputSource source) Set the input source for the C program.voidsetSourceLanguage(CCompilerInvoker.SourceLanguage sourceLanguage) Methods inherited from interface org.qbicc.machine.tool.MessagingToolInvoker
getMessageHandler, setMessageHandlerMethods inherited from interface org.qbicc.machine.tool.ToolInvoker
getPath, getTool, invoke
-
Method Details
-
addIncludePath
Add an include path.- Parameters:
path- the include path to add (must not benull)
-
addIncludePaths
Add all the given include paths.- Parameters:
paths- the include paths to add (must not benull)
-
getIncludePathCount
int getIncludePathCount()Get the number of include paths defined.- Returns:
- the number of include paths
-
getIncludePath
Get the include path at the given index.- Parameters:
index- the index- Returns:
- the include path
- Throws:
IndexOutOfBoundsException- if the index is out of bounds
-
addDefinedSymbol
Define a symbol to the C compiler to "1".- Parameters:
name- the symbol to define (must not benull)
-
addDefinedSymbol
Define a symbol to the C compiler.- Parameters:
name- the symbol to define (must not benull)value- the value to give to the defined symbol (must not benull)
-
getDefinedSymbolCount
int getDefinedSymbolCount()Get the number of defined symbols.- Returns:
- the number of defined symbols
-
getDefinedSymbol
Get the defined symbol at the given index.- Parameters:
index- the index- Returns:
- the defined symbol
- Throws:
IndexOutOfBoundsException- if the index is out of bounds
-
getDefinedSymbolValue
Get the defined symbol value.- Parameters:
index- the index- Returns:
- the defined symbol value
- Throws:
IndexOutOfBoundsException- if the index is out of bounds
-
setSource
Set the input source for the C program.- Parameters:
source- the input source (must not benull)
-
getSource
InputSource getSource()Get the input source for the C program.- Returns:
- the input source (not
null)
-
setOutputPath
Set the object file output path.- Parameters:
path- the output path (must not benull)
-
getSourceLanguage
CCompilerInvoker.SourceLanguage getSourceLanguage() -
setSourceLanguage
-
getOutputPath
Get the object file output path.- Returns:
- the output path
- Throws:
IllegalArgumentException- if the output path has not been set
-