C# Class MonoDevelop.Projects.DotNetProject

Inheritance: Project, IAssemblyProject
Exibir arquivo Open project: LogosBible/monodevelop Class Usage Examples

Protected Properties

Property Type Description
projectReferences ProjectReferenceCollection

Private Properties

Property Type Description
CheckReferenceChange void
FindLanguage IDotNetLanguageBinding
GetAssemblyRefsRec IEnumerable
GetHierarchicalNamespace string
GetResourceCulture string
GetTargetFrameworkForNewProject MonoDevelop.Core.Assemblies.TargetFramework
MigrateResourceIds void
NotifyReferenceAddedToProject void
NotifyReferenceRemovedFromProject void
OnFileChanged void
OnFileRemoved void
PopulateSupportFileListInternal void
RenameReferences void
RuntimeSystemAssemblyServiceDefaultRuntimeChanged void
SanitisePotentialNamespace string
SetItemHandler void
UpdateSystemReferences void

Public Methods

Method Description
AddReference ( string filename ) : MonoDevelop.Projects.ProjectReference
CanReferenceProject ( DotNetProject targetProject, string &reason ) : bool
CreateConfiguration ( string name ) : MonoDevelop.Projects.SolutionItemConfiguration
Dispose ( ) : void
DotNetProject ( ) : System
DotNetProject ( string languageName ) : System
DotNetProject ( string languageName, MonoDevelop.Projects.ProjectCreateInformation projectCreateInfo, XmlElement projectOptions ) : System
GetDefaultNamespace ( string fileName ) : string

Gets the default namespace for the file, according to the naming policy.

Always returns a valid namespace, even if the fileName is null.

GetDefaultTargetFrameworkForFormat ( MonoDevelop.Projects.FileFormat format ) : TargetFrameworkMoniker

Returns the default framework for a given format

This method is used to determine what's the correct target framework for a project deserialized using a specific format.

GetDefaultTargetFrameworkId ( ) : TargetFrameworkMoniker

Gets the target framework for new projects

GetOutputFileName ( MonoDevelop.Projects.ConfigurationSelector configuration ) : FilePath
GetReferencedAssemblies ( MonoDevelop.Projects.ConfigurationSelector configuration ) : IEnumerable

Returns all assemblies referenced by this project, including assemblies generated by referenced projects.

GetReferencedAssemblies ( MonoDevelop.Projects.ConfigurationSelector configuration, bool includeProjectReferences ) : IEnumerable

Returns all assemblies referenced by this project.

GetReferencedItems ( MonoDevelop.Projects.ConfigurationSelector configuration ) : IEnumerable
GetUserAssemblyPaths ( MonoDevelop.Projects.ConfigurationSelector configuration ) : IList
IsCompileable ( string fileName ) : bool
StripImplicitNamespace ( string ns ) : string

Given a namespace, removes from it the implicit namespace of the project, if there is one. This depends on the target language. For example, in VB.NET the default namespace is implicit.

SupportsFramework ( MonoDevelop.Core.Assemblies.TargetFramework framework ) : bool
UpdateResourceHandler ( bool keepOldIds ) : void

Protected Methods

Method Description
CheckNeedsBuild ( MonoDevelop.Projects.ConfigurationSelector configuration ) : bool
CreateExecutionCommand ( MonoDevelop.Projects.ConfigurationSelector configSel, DotNetProjectConfiguration configuration ) : MonoDevelop.Core.Execution.ExecutionCommand
DoExecute ( IProgressMonitor monitor, ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration ) : void
GetCommonBuildActions ( ) : IList
GetDefaultTargetPlatform ( MonoDevelop.Projects.ProjectCreateInformation projectCreateInfo ) : string
GetStandardBuildActions ( ) : IEnumerable
OnEndLoad ( ) : void
OnGetCanExecute ( ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration ) : bool
OnGetItemFiles ( bool includeReferencedFiles ) : List
OnGetLastBuildTime ( MonoDevelop.Projects.ConfigurationSelector configuration ) : System.DateTime
OnGetReferencedAssemblies ( MonoDevelop.Projects.ConfigurationSelector configuration, bool includeProjectReferences ) : IEnumerable
OnItemsAdded ( IEnumerable objs ) : void
OnItemsRemoved ( IEnumerable objs ) : void
OnReferenceAddedToProject ( MonoDevelop.Projects.ProjectReferenceEventArgs e ) : void
OnReferenceRemovedFromProject ( MonoDevelop.Projects.ProjectReferenceEventArgs e ) : void
OnSave ( IProgressMonitor monitor ) : void
PopulateOutputFileList ( List list, MonoDevelop.Projects.ConfigurationSelector configuration ) : void
PopulateSupportFileList ( FileCopySet list, MonoDevelop.Projects.ConfigurationSelector configuration ) : void

Private Methods

Method Description
CheckReferenceChange ( string updatedFile ) : void
FindLanguage ( string name ) : IDotNetLanguageBinding
GetAssemblyRefsRec ( string fileName, HashSet visited ) : IEnumerable
GetHierarchicalNamespace ( string relativePath ) : string
GetResourceCulture ( string fname ) : string
GetTargetFrameworkForNewProject ( XmlElement projectOptions, TargetFrameworkMoniker defaultMoniker ) : MonoDevelop.Core.Assemblies.TargetFramework
MigrateResourceIds ( IResourceHandler oldHandler, IResourceHandler newHandler ) : void
NotifyReferenceAddedToProject ( MonoDevelop.Projects.ProjectReference reference ) : void
NotifyReferenceRemovedFromProject ( MonoDevelop.Projects.ProjectReference reference ) : void
OnFileChanged ( object source, MonoDevelop e ) : void
OnFileRemoved ( Object o, FileEventArgs e ) : void
PopulateSupportFileListInternal ( FileCopySet list, MonoDevelop.Projects.ConfigurationSelector configuration ) : void
RenameReferences ( string oldName, string newName ) : void
RuntimeSystemAssemblyServiceDefaultRuntimeChanged ( object sender, EventArgs e ) : void
SanitisePotentialNamespace ( string potential ) : string
SetItemHandler ( ISolutionItemHandler handler ) : void
UpdateSystemReferences ( ) : void

Method Details

AddReference() public method

public AddReference ( string filename ) : MonoDevelop.Projects.ProjectReference
filename string
return MonoDevelop.Projects.ProjectReference

CanReferenceProject() public method

public CanReferenceProject ( DotNetProject targetProject, string &reason ) : bool
targetProject DotNetProject
reason string
return bool

CheckNeedsBuild() protected method

protected CheckNeedsBuild ( MonoDevelop.Projects.ConfigurationSelector configuration ) : bool
configuration MonoDevelop.Projects.ConfigurationSelector
return bool

CreateConfiguration() public method

public CreateConfiguration ( string name ) : MonoDevelop.Projects.SolutionItemConfiguration
name string
return MonoDevelop.Projects.SolutionItemConfiguration

CreateExecutionCommand() protected method

protected CreateExecutionCommand ( MonoDevelop.Projects.ConfigurationSelector configSel, DotNetProjectConfiguration configuration ) : MonoDevelop.Core.Execution.ExecutionCommand
configSel MonoDevelop.Projects.ConfigurationSelector
configuration DotNetProjectConfiguration
return MonoDevelop.Core.Execution.ExecutionCommand

Dispose() public method

public Dispose ( ) : void
return void

DoExecute() protected method

protected DoExecute ( IProgressMonitor monitor, ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration ) : void
monitor IProgressMonitor
context ExecutionContext
configuration MonoDevelop.Projects.ConfigurationSelector
return void

DotNetProject() public method

public DotNetProject ( ) : System
return System

DotNetProject() public method

public DotNetProject ( string languageName ) : System
languageName string
return System

DotNetProject() public method

public DotNetProject ( string languageName, MonoDevelop.Projects.ProjectCreateInformation projectCreateInfo, XmlElement projectOptions ) : System
languageName string
projectCreateInfo MonoDevelop.Projects.ProjectCreateInformation
projectOptions System.Xml.XmlElement
return System

GetCommonBuildActions() protected method

protected GetCommonBuildActions ( ) : IList
return IList

GetDefaultNamespace() public method

Gets the default namespace for the file, according to the naming policy.
Always returns a valid namespace, even if the fileName is null.
public GetDefaultNamespace ( string fileName ) : string
fileName string
return string

GetDefaultTargetFrameworkForFormat() public method

Returns the default framework for a given format
This method is used to determine what's the correct target framework for a project deserialized using a specific format.
public GetDefaultTargetFrameworkForFormat ( MonoDevelop.Projects.FileFormat format ) : TargetFrameworkMoniker
format MonoDevelop.Projects.FileFormat /// A format ///
return TargetFrameworkMoniker

GetDefaultTargetFrameworkId() public method

Gets the target framework for new projects
public GetDefaultTargetFrameworkId ( ) : TargetFrameworkMoniker
return TargetFrameworkMoniker

GetDefaultTargetPlatform() protected method

protected GetDefaultTargetPlatform ( MonoDevelop.Projects.ProjectCreateInformation projectCreateInfo ) : string
projectCreateInfo MonoDevelop.Projects.ProjectCreateInformation
return string

GetOutputFileName() public method

public GetOutputFileName ( MonoDevelop.Projects.ConfigurationSelector configuration ) : FilePath
configuration MonoDevelop.Projects.ConfigurationSelector
return FilePath

GetReferencedAssemblies() public method

Returns all assemblies referenced by this project, including assemblies generated by referenced projects.
public GetReferencedAssemblies ( MonoDevelop.Projects.ConfigurationSelector configuration ) : IEnumerable
configuration MonoDevelop.Projects.ConfigurationSelector /// Configuration for which to get the assemblies. ///
return IEnumerable

GetReferencedAssemblies() public method

Returns all assemblies referenced by this project.
public GetReferencedAssemblies ( MonoDevelop.Projects.ConfigurationSelector configuration, bool includeProjectReferences ) : IEnumerable
configuration MonoDevelop.Projects.ConfigurationSelector /// Configuration for which to get the assemblies. ///
includeProjectReferences bool /// When set to true, it will include assemblies generated by referenced project. When set to false, /// it will only include package and direct assembly references. ///
return IEnumerable

GetReferencedItems() public method

public GetReferencedItems ( MonoDevelop.Projects.ConfigurationSelector configuration ) : IEnumerable
configuration MonoDevelop.Projects.ConfigurationSelector
return IEnumerable

GetStandardBuildActions() protected method

protected GetStandardBuildActions ( ) : IEnumerable
return IEnumerable

GetUserAssemblyPaths() public method

public GetUserAssemblyPaths ( MonoDevelop.Projects.ConfigurationSelector configuration ) : IList
configuration MonoDevelop.Projects.ConfigurationSelector
return IList

IsCompileable() public method

public IsCompileable ( string fileName ) : bool
fileName string
return bool

OnEndLoad() protected method

protected OnEndLoad ( ) : void
return void

OnGetCanExecute() protected method

protected OnGetCanExecute ( ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration ) : bool
context ExecutionContext
configuration MonoDevelop.Projects.ConfigurationSelector
return bool

OnGetItemFiles() protected method

protected OnGetItemFiles ( bool includeReferencedFiles ) : List
includeReferencedFiles bool
return List

OnGetLastBuildTime() protected method

protected OnGetLastBuildTime ( MonoDevelop.Projects.ConfigurationSelector configuration ) : System.DateTime
configuration MonoDevelop.Projects.ConfigurationSelector
return System.DateTime

OnGetReferencedAssemblies() protected method

protected OnGetReferencedAssemblies ( MonoDevelop.Projects.ConfigurationSelector configuration, bool includeProjectReferences ) : IEnumerable
configuration MonoDevelop.Projects.ConfigurationSelector
includeProjectReferences bool
return IEnumerable

OnItemsAdded() protected method

protected OnItemsAdded ( IEnumerable objs ) : void
objs IEnumerable
return void

OnItemsRemoved() protected method

protected OnItemsRemoved ( IEnumerable objs ) : void
objs IEnumerable
return void

OnReferenceAddedToProject() protected method

protected OnReferenceAddedToProject ( MonoDevelop.Projects.ProjectReferenceEventArgs e ) : void
e MonoDevelop.Projects.ProjectReferenceEventArgs
return void

OnReferenceRemovedFromProject() protected method

protected OnReferenceRemovedFromProject ( MonoDevelop.Projects.ProjectReferenceEventArgs e ) : void
e MonoDevelop.Projects.ProjectReferenceEventArgs
return void

OnSave() protected method

protected OnSave ( IProgressMonitor monitor ) : void
monitor IProgressMonitor
return void

PopulateOutputFileList() protected method

protected PopulateOutputFileList ( List list, MonoDevelop.Projects.ConfigurationSelector configuration ) : void
list List
configuration MonoDevelop.Projects.ConfigurationSelector
return void

PopulateSupportFileList() protected method

protected PopulateSupportFileList ( FileCopySet list, MonoDevelop.Projects.ConfigurationSelector configuration ) : void
list FileCopySet
configuration MonoDevelop.Projects.ConfigurationSelector
return void

StripImplicitNamespace() public method

Given a namespace, removes from it the implicit namespace of the project, if there is one. This depends on the target language. For example, in VB.NET the default namespace is implicit.
public StripImplicitNamespace ( string ns ) : string
ns string
return string

SupportsFramework() public method

public SupportsFramework ( MonoDevelop.Core.Assemblies.TargetFramework framework ) : bool
framework MonoDevelop.Core.Assemblies.TargetFramework
return bool

UpdateResourceHandler() public method

public UpdateResourceHandler ( bool keepOldIds ) : void
keepOldIds bool
return void

Property Details

projectReferences protected_oe property

protected ProjectReferenceCollection projectReferences
return ProjectReferenceCollection