Class CSharpCompiler
java.lang.Object
org.codehaus.plexus.logging.AbstractLogEnabled
org.codehaus.plexus.compiler.AbstractCompiler
org.codehaus.plexus.compiler.csharp.CSharpCompiler
- All Implemented Interfaces:
Compiler
,org.codehaus.plexus.logging.LogEnabled
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final String
private static final String[]
private static final String
private static final String
private static final String
Fields inherited from class org.codehaus.plexus.compiler.AbstractCompiler
EOL, PS
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate void
addResourceArgs
(CompilerConfiguration config, List<String> args) private String[]
buildCompilerArguments
(CompilerConfiguration config, String[] sourceFiles) boolean
canUpdateTarget
(CompilerConfiguration configuration) private List<CompilerMessage>
compileOutOfProcess
(File workingDirectory, File target, String executable, String[] args) private String
String[]
Create the command line that would be executed using this configuration.private String
findExecutable
(CompilerConfiguration config) private File
findResourceDir
(CompilerConfiguration config) getOutputFile
(CompilerConfiguration configuration) protected static String[]
getSourceFiles
(CompilerConfiguration config) getSourceFilesForSourceRoot
(CompilerConfiguration config, String sourceLocation) private String
private String
getTypeExtension
(CompilerConfiguration configuration) static List<CompilerMessage>
parseCompilerOutput
(BufferedReader bufferedReader) static CompilerMessage
Deprecated.performCompile
(CompilerConfiguration config) Performs the compilation of the project.Methods inherited from class org.codehaus.plexus.compiler.AbstractCompiler
compile, getCompilerOutputStyle, getInputFileEnding, getOutputFileEnding, getPathString, makeClassName, toStringArray
Methods inherited from class org.codehaus.plexus.logging.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.codehaus.plexus.compiler.Compiler
supportsIncrementalCompilation
-
Field Details
-
JAR_SUFFIX
- See Also:
-
DLL_SUFFIX
- See Also:
-
NET_SUFFIX
- See Also:
-
ARGUMENTS_FILE_NAME
- See Also:
-
DEFAULT_INCLUDES
-
compilerArguments
-
-
Constructor Details
-
CSharpCompiler
public CSharpCompiler()
-
-
Method Details
-
canUpdateTarget
- Specified by:
canUpdateTarget
in interfaceCompiler
- Overrides:
canUpdateTarget
in classAbstractCompiler
- Throws:
CompilerException
-
getOutputFile
- Specified by:
getOutputFile
in interfaceCompiler
- Overrides:
getOutputFile
in classAbstractCompiler
- Throws:
CompilerException
-
performCompile
Description copied from interface:Compiler
Performs the compilation of the project. Clients must implement this method.- Specified by:
performCompile
in interfaceCompiler
- Overrides:
performCompile
in classAbstractCompiler
- Parameters:
config
- the configuration description of the compilation to perform- Returns:
- the result of the compilation returned by the language processor
- Throws:
CompilerException
-
createCommandLine
Description copied from interface:Compiler
Create the command line that would be executed using this configuration. If this particular compiler has no concept of a command line then returns null.- Parameters:
config
- the CompilerConfiguration describing the compilation- Returns:
- an array of Strings that make up the command line, or null if this compiler has no concept of command line
- Throws:
CompilerException
- if there was an error generating the command line
-
getCompilerArguments
-
findExecutable
-
buildCompilerArguments
private String[] buildCompilerArguments(CompilerConfiguration config, String[] sourceFiles) throws CompilerException - Throws:
CompilerException
-
addResourceArgs
-
findResourceDir
-
convertNameToAssemblyResourceName
-
compileOutOfProcess
private List<CompilerMessage> compileOutOfProcess(File workingDirectory, File target, String executable, String[] args) throws CompilerException - Throws:
CompilerException
-
parseCompilerOutput
public static List<CompilerMessage> parseCompilerOutput(BufferedReader bufferedReader) throws IOException - Throws:
IOException
-
getType
-
getTypeExtension
- Throws:
CompilerException
-
getSourceFiles
-
parseLine
Deprecated.This method is just here to maintain the public api. This is now handled in the parse compiler output function. -
getSourceFilesForSourceRoot
protected static Set<String> getSourceFilesForSourceRoot(CompilerConfiguration config, String sourceLocation)
-