C# Класс NAnt.VSNet.ProjectBase

Base class for all project classes.
Показать файл Открыть проект Примеры использования класса

Private Properties

Свойство Тип Описание

Открытые методы

Метод Описание
Compile ( NAnt.VSNet.Configuration solutionConfiguration ) : bool
CreateProjectReference ( ProjectBase project, bool isPrivateSpecified, bool isPrivate ) : ProjectReferenceBase
GetAssemblyReferences ( NAnt.VSNet.Configuration solutionConfiguration ) : StringCollection
GetConfiguration ( NAnt.VSNet.Configuration solutionConfiguration ) : NAnt.VSNet.ConfigurationBase
GetOutputFiles ( NAnt.VSNet.Configuration solutionConfiguration, Hashtable outputFiles ) : void

Gets the complete set of output files for the project configuration matching the specified solution configuration.

The key of the case-insensitive Hashtable is the full path of the output file and the value is the path relative to the output directory.

If the project is not configured to be built for the specified solution configuration, then no output files are added.

GetOutputPath ( NAnt.VSNet.Configuration solutionConfiguration ) : string
IsManaged ( NAnt.VSNet.Configuration configuration ) : bool

Gets a value indicating whether building the project for the specified build configuration results in managed output.

Защищенные методы

Метод Описание
Build ( NAnt.VSNet.Configuration solutionConfiguration ) : BuildResult
CopyFile ( FileInfo srcFile, FileInfo destFile, NAnt.Core.Task parent ) : void

Copies the specified file if the destination file does not exist, or the source file has been modified since it was previously copied.

DetermineProductVersion ( XmlElement docElement ) : ProductVersion

Returns the Visual Studio product version of the specified project XML fragment.

ExecuteBuildEvent ( string buildEvent, string buildCommandLine, string batchFile, string workingDirectory, NAnt.VSNet.ConfigurationBase config ) : bool
ExpandMacro ( string macro ) : string

Expands the given macro.

Log ( Level messageLevel, string message ) : void

Logs a message with the given priority.

The actual logging is delegated to the underlying task.

Prepare ( NAnt.VSNet.Configuration solutionConfiguration ) : void

Prepares the project for being built.

The default implementation will ensure that none of the output files are marked read-only.

ProjectBase ( XmlElement xmlDefinition, NAnt.VSNet.Tasks.SolutionTask solutionTask, TempFileCollection temporaryFiles, GacCache gacCache, ReferencesResolver referencesResolver, DirectoryInfo outputDir ) : System

Initializes a new instance of the ProjectBase class.

VerifyProjectXml ( XmlElement docElement ) : void

Verifies whether the specified XML fragment represents a valid project that is supported by this ProjectBase.

Описание методов

Build() защищенный абстрактный Метод

protected abstract Build ( NAnt.VSNet.Configuration solutionConfiguration ) : BuildResult
solutionConfiguration NAnt.VSNet.Configuration
Результат BuildResult

Compile() публичный Метод

public Compile ( NAnt.VSNet.Configuration solutionConfiguration ) : bool
solutionConfiguration NAnt.VSNet.Configuration
Результат bool

CopyFile() защищенный Метод

Copies the specified file if the destination file does not exist, or the source file has been modified since it was previously copied.
protected CopyFile ( FileInfo srcFile, FileInfo destFile, NAnt.Core.Task parent ) : void
srcFile System.IO.FileInfo The file to copy.
destFile System.IO.FileInfo The destination file.
parent NAnt.Core.Task The in which context the operation will be performed.
Результат void

CreateProjectReference() публичный абстрактный Метод

public abstract CreateProjectReference ( ProjectBase project, bool isPrivateSpecified, bool isPrivate ) : ProjectReferenceBase
project ProjectBase
isPrivateSpecified bool
isPrivate bool
Результат ProjectReferenceBase

DetermineProductVersion() защищенный абстрактный Метод

Returns the Visual Studio product version of the specified project XML fragment.
/// The product version could not be determined. /// -or- /// The product version is not supported. ///
protected abstract DetermineProductVersion ( XmlElement docElement ) : ProductVersion
docElement System.Xml.XmlElement XML fragment representing the project file.
Результат ProductVersion

ExecuteBuildEvent() защищенный Метод

protected ExecuteBuildEvent ( string buildEvent, string buildCommandLine, string batchFile, string workingDirectory, NAnt.VSNet.ConfigurationBase config ) : bool
buildEvent string
buildCommandLine string
batchFile string
workingDirectory string
config NAnt.VSNet.ConfigurationBase
Результат bool

ExpandMacro() защищенный Метод

Expands the given macro.
protected ExpandMacro ( string macro ) : string
macro string The macro to expand.
Результат string

GetAssemblyReferences() публичный Метод

public GetAssemblyReferences ( NAnt.VSNet.Configuration solutionConfiguration ) : StringCollection
solutionConfiguration NAnt.VSNet.Configuration
Результат System.Collections.Specialized.StringCollection

GetConfiguration() публичный Метод

public GetConfiguration ( NAnt.VSNet.Configuration solutionConfiguration ) : NAnt.VSNet.ConfigurationBase
solutionConfiguration NAnt.VSNet.Configuration
Результат NAnt.VSNet.ConfigurationBase

GetOutputFiles() публичный Метод

Gets the complete set of output files for the project configuration matching the specified solution configuration.

The key of the case-insensitive Hashtable is the full path of the output file and the value is the path relative to the output directory.

If the project is not configured to be built for the specified solution configuration, then no output files are added.

public GetOutputFiles ( NAnt.VSNet.Configuration solutionConfiguration, Hashtable outputFiles ) : void
solutionConfiguration NAnt.VSNet.Configuration The solution configuration that is built.
outputFiles System.Collections.Hashtable The set of output files to be updated.
Результат void

GetOutputPath() публичный Метод

public GetOutputPath ( NAnt.VSNet.Configuration solutionConfiguration ) : string
solutionConfiguration NAnt.VSNet.Configuration
Результат string

IsManaged() публичный абстрактный Метод

Gets a value indicating whether building the project for the specified build configuration results in managed output.
public abstract IsManaged ( NAnt.VSNet.Configuration configuration ) : bool
configuration NAnt.VSNet.Configuration The build configuration.
Результат bool

Log() защищенный Метод

Logs a message with the given priority.
The actual logging is delegated to the underlying task.
protected Log ( Level messageLevel, string message ) : void
messageLevel Level The message priority at which the specified message is to be logged.
message string The message to be logged.
Результат void

Prepare() защищенный Метод

Prepares the project for being built.
The default implementation will ensure that none of the output files are marked read-only.
protected Prepare ( NAnt.VSNet.Configuration solutionConfiguration ) : void
solutionConfiguration NAnt.VSNet.Configuration The solution configuration that is built.
Результат void

ProjectBase() защищенный Метод

Initializes a new instance of the ProjectBase class.
protected ProjectBase ( XmlElement xmlDefinition, NAnt.VSNet.Tasks.SolutionTask solutionTask, TempFileCollection temporaryFiles, GacCache gacCache, ReferencesResolver referencesResolver, DirectoryInfo outputDir ) : System
xmlDefinition System.Xml.XmlElement
solutionTask NAnt.VSNet.Tasks.SolutionTask
temporaryFiles System.CodeDom.Compiler.TempFileCollection
gacCache NAnt.Core.Util.GacCache
referencesResolver ReferencesResolver
outputDir System.IO.DirectoryInfo
Результат System

VerifyProjectXml() защищенный абстрактный Метод

Verifies whether the specified XML fragment represents a valid project that is supported by this ProjectBase.
/// The XML fragment is not supported by this . /// -or- /// The XML fragment does not represent a valid project (for this ). ///
protected abstract VerifyProjectXml ( XmlElement docElement ) : void
docElement System.Xml.XmlElement XML fragment representing the project file.
Результат void