C# Class Nemerle.VisualStudio.Project.NemerleProjectNode

Inheritance: Microsoft.VisualStudio.Project.ProjectNode, IVsProjectSpecificEditorMap2
Show file Open project: rsdn/nemerle Class Usage Examples

Private Properties

Property Type Description
AddFileNodeToNode HierarchyNode
AddIndependentFileNode HierarchyNode
AddManyItemsHelper int
CreateFolderNode Microsoft.VisualStudio.Project.FolderNode
CreateFolderNodeHelper HierarchyNode
CreateFolderNodeHelper HierarchyNode
CreateMsBuildFileProjectElement Microsoft.VisualStudio.Project.ProjectElement
CreateMsBuildFolderProjectElement Microsoft.VisualStudio.Project.ProjectElement
CreateServices object
DeleteTempCmdFile void
FindChildEx HierarchyNode
FindProject EnvDTE.Project
GetItemParentNode HierarchyNode
GetNamespace string
GetProject EnvDTE.Project
IVsProjectSpecificEditorMap2 int
InitializeCATIDs void
IsLinkNode bool
LoadProjectImageList System.Windows.Forms.ImageList
StartNoDebug bool
ToggleShowAllFiles int
TryFindParentFileNode bool

Public Methods

Method Description
AddComponent ( VSADDCOMPOPERATION dwAddCompOperation, uint cComponents, System rgpcsdComponents, System hwndDialog, VSADDCOMPRESULT pResult ) : int

Add Components to the Project. Used by the environment to add components specified by the user in the Component Selector dialog to the specified project

AddFileFromTemplate ( string source, string target ) : void

Overriding to provide customization of files on add files. This will replace tokens in the file with actual value (namespace, class name,...)

AddItem ( uint itemIdLoc, VSADDITEMOPERATION op, string itemName, uint filesToOpen, string files, IntPtr dlgOwner, VSADDRESULT result ) : int
AddProjectReference ( ) : int

This overrides the base class method to show the VS 2005 style Add reference dialog. The ProjectNode implementation shows the VS 2003 style Add Reference dialog.

Close ( ) : int
CreateDependentFileNode ( ProjectElement item ) : FileNode

Create dependent file node based on an msbuild item

CreateFileNode ( ProjectElement item ) : FileNode

Create a file node based on an msbuild item.

CreateFolderNodes ( string path ) : HierarchyNode

Walks the subpaths of a project relative path and checks if the folder nodes hierarchy is already there, if not creates it.

GetAutomationObject ( ) : object

Gets the automation object for the project node.

GetFile ( int fileId, uint flags, uint &itemid, string &fileName ) : int

Allows you to query the project for special files and optionally create them.

GetFormatList ( string &formatlist ) : int

Creates the format list for the open file dialog

GetGuidProperty ( int propid, System.Guid &guid ) : int
GetMacroReferenceContainer ( ) : IReferenceContainer
GetOutputExtension ( OutputType outputType ) : string
GetProjectOptions ( string config ) : ProjectOptions
GetProperty ( int propId ) : object
GetServiceProvider ( ) : IServiceProvider
GetSpecificEditorProperty ( string mkDocument, int propid, object &result ) : int
GetSpecificEditorType ( string mkDocument, System.Guid &guidEditorType ) : int
IsCodeFile ( string strFileName ) : bool

Evaluates if a file is an Nemerle code file based on is extension

IsEmbeddedResource ( string strFileName ) : bool
Load ( string filename, string location, string name, uint flags, System.Guid &iidProject, int &canceled ) : void
NemerleProjectNode ( NemerlePackage pkg ) : System
OpenItem ( uint itemId, System.Guid &logicalView, IntPtr punkDocDataExisting, IVsWindowFrame &frame ) : int
PrepareBuild ( string config, bool cleanBuild ) : void
SetSite ( Microsoft site ) : int
SetSpecificEditorProperty ( string mkDocument, int propid, object value ) : int

Protected Methods

Method Description
AddNewFileNodeToHierarchy ( HierarchyNode parentNode, string fileName ) : void
AddWizardCustomParams ( HierarchyNode parent, string file, string>.Dictionary customParams ) : void
CreateConfigProvider ( ) : ConfigProvider
CreatePropertiesObject ( ) : NodeProperties
CreateReferenceContainerNode ( ) : ReferenceContainerNode
Dispose ( bool disposing ) : void
GetConfigurationDependentPropertyPages ( ) : System.Guid[]

Returns the configuration dependent property pages. Specify here a property page. By returning no property page the configuartion dependent properties will be neglected. Overriding, but current implementation does nothing. To provide configuration specific page project property page, this should return an array bigger then 0 (you can make it do the same as GetConfigurationIndependentPropertyPages() to see its impact)

GetConfigurationIndependentPropertyPages ( ) : System.Guid[]

Overriding to provide project general property page

InternalExecCommand ( System.Guid cmdGroup, uint cmdId, uint cmdExecOpt, IntPtr vaIn, IntPtr vaOut, CommandOrigin commandOrigin ) : int
IsItemTypeFileType ( string type ) : bool
OnHandleConfigurationRelatedGlobalProperties ( object sender, ActiveConfigurationChangedEventArgs eventArgs ) : void
ProcessFiles ( ) : void

Loads file items from the project file into the hierarchy.

ProcessFolders ( ) : void
ProcessReferences ( ) : void
SetOutputLogger ( IVsOutputWindowPane output ) : void
ShowAllFiles ( ) : int

Enables / Disables the ShowAllFileMode.

Private Methods

Method Description
AddFileNodeToNode ( Microsoft.Build.Evaluation item, HierarchyNode parentNode ) : HierarchyNode

Add a file node to the hierarchy

AddIndependentFileNode ( Microsoft.Build.Evaluation item ) : HierarchyNode

Add an item to the hierarchy based on the item path

AddManyItemsHelper ( uint itemIdLoc, VSADDITEMOPERATION op, string itemName, uint filesToOpen, string files, IntPtr dlgOwner, VSADDRESULT result ) : int
CreateFolderNode ( string path, ProjectElement element ) : FolderNode
CreateFolderNodeHelper ( string sourcePath, string parentPath ) : HierarchyNode
CreateFolderNodeHelper ( string directory, uint parentID ) : HierarchyNode
CreateMsBuildFileProjectElement ( string file ) : ProjectElement

Creates and returns the ProjectElement for a file item.

CreateMsBuildFolderProjectElement ( string folder ) : ProjectElement

Creates and returns the ProjectElement for a folder item.

CreateServices ( Type serviceType ) : object

Creates the services exposed by this project.

DeleteTempCmdFile ( Process process, string cmdFilePath ) : void
FindChildEx ( HierarchyNode it, string name ) : HierarchyNode
FindProject ( EnvDTE project, string projectFullName ) : EnvDTE.Project
GetItemParentNode ( Microsoft.Build.Evaluation item ) : HierarchyNode

Get the parent node of an msbuild item

GetNamespace ( HierarchyNode node ) : string
GetProject ( EnvDTE dte, string startupProjectFullName ) : EnvDTE.Project
IVsProjectSpecificEditorMap2 ( string mkDocument, System.Guid &guidLanguageService ) : int
InitializeCATIDs ( ) : void

Provide mapping from our browse objects and automation objects to our CATIDs

IsLinkNode ( Microsoft.Build.Evaluation item ) : bool
LoadProjectImageList ( ) : ImageList
StartNoDebug ( EnvDTE dte ) : bool

Run project output without debugging.

ToggleShowAllFiles ( ) : int

Toggles the state of Show all files

TryFindParentFileNode ( HierarchyNode root, string child, HierarchyNode &parent ) : bool

Method Details

AddComponent() public method

Add Components to the Project. Used by the environment to add components specified by the user in the Component Selector dialog to the specified project
public AddComponent ( VSADDCOMPOPERATION dwAddCompOperation, uint cComponents, System rgpcsdComponents, System hwndDialog, VSADDCOMPRESULT pResult ) : int
dwAddCompOperation VSADDCOMPOPERATION The component operation to be performed.
cComponents uint Number of components to be added
rgpcsdComponents System array of component selector data
hwndDialog System Handle to the component picker dialog
pResult VSADDCOMPRESULT Result to be returned to the caller
return int

AddFileFromTemplate() public method

Overriding to provide customization of files on add files. This will replace tokens in the file with actual value (namespace, class name,...)
public AddFileFromTemplate ( string source, string target ) : void
source string Full path to template file
target string Full path to destination file
return void

AddItem() public method

public AddItem ( uint itemIdLoc, VSADDITEMOPERATION op, string itemName, uint filesToOpen, string files, IntPtr dlgOwner, VSADDRESULT result ) : int
itemIdLoc uint
op VSADDITEMOPERATION
itemName string
filesToOpen uint
files string
dlgOwner System.IntPtr
result VSADDRESULT
return int

AddNewFileNodeToHierarchy() protected method

protected AddNewFileNodeToHierarchy ( HierarchyNode parentNode, string fileName ) : void
parentNode HierarchyNode
fileName string
return void

AddProjectReference() public method

This overrides the base class method to show the VS 2005 style Add reference dialog. The ProjectNode implementation shows the VS 2003 style Add Reference dialog.
public AddProjectReference ( ) : int
return int

AddWizardCustomParams() protected method

protected AddWizardCustomParams ( HierarchyNode parent, string file, string>.Dictionary customParams ) : void
parent HierarchyNode
file string
customParams string>.Dictionary
return void

Close() public method

public Close ( ) : int
return int

CreateConfigProvider() protected method

protected CreateConfigProvider ( ) : ConfigProvider
return Microsoft.VisualStudio.Project.ConfigProvider

CreateDependentFileNode() public method

Create dependent file node based on an msbuild item
public CreateDependentFileNode ( ProjectElement item ) : FileNode
item Microsoft.VisualStudio.Project.ProjectElement msbuild item
return Microsoft.VisualStudio.Project.FileNode

CreateFileNode() public method

Create a file node based on an msbuild item.
public CreateFileNode ( ProjectElement item ) : FileNode
item Microsoft.VisualStudio.Project.ProjectElement The msbuild item to be analyzed
return Microsoft.VisualStudio.Project.FileNode

CreateFolderNodes() public method

Walks the subpaths of a project relative path and checks if the folder nodes hierarchy is already there, if not creates it.
public CreateFolderNodes ( string path ) : HierarchyNode
path string Path of the folder, can be relative to project or absolute
return HierarchyNode

CreatePropertiesObject() protected method

protected CreatePropertiesObject ( ) : NodeProperties
return Microsoft.VisualStudio.Project.NodeProperties

CreateReferenceContainerNode() protected method

protected CreateReferenceContainerNode ( ) : ReferenceContainerNode
return Microsoft.VisualStudio.Project.ReferenceContainerNode

Dispose() protected method

protected Dispose ( bool disposing ) : void
disposing bool
return void

GetAutomationObject() public method

Gets the automation object for the project node.
public GetAutomationObject ( ) : object
return object

GetConfigurationDependentPropertyPages() protected method

Returns the configuration dependent property pages. Specify here a property page. By returning no property page the configuartion dependent properties will be neglected. Overriding, but current implementation does nothing. To provide configuration specific page project property page, this should return an array bigger then 0 (you can make it do the same as GetConfigurationIndependentPropertyPages() to see its impact)
protected GetConfigurationDependentPropertyPages ( ) : System.Guid[]
return System.Guid[]

GetConfigurationIndependentPropertyPages() protected method

Overriding to provide project general property page
protected GetConfigurationIndependentPropertyPages ( ) : System.Guid[]
return System.Guid[]

GetFile() public method

Allows you to query the project for special files and optionally create them.
public GetFile ( int fileId, uint flags, uint &itemid, string &fileName ) : int
fileId int __PSFFILEID of the file
flags uint __PSFFLAGS flags for the file
itemid uint The itemid of the node in the hierarchy
fileName string The file name of the special file.
return int

GetFormatList() public method

Creates the format list for the open file dialog
public GetFormatList ( string &formatlist ) : int
formatlist string The formatlist to return
return int

GetGuidProperty() public method

public GetGuidProperty ( int propid, System.Guid &guid ) : int
propid int
guid System.Guid
return int

GetMacroReferenceContainer() public method

public GetMacroReferenceContainer ( ) : IReferenceContainer
return IReferenceContainer

GetOutputExtension() public static method

public static GetOutputExtension ( OutputType outputType ) : string
outputType OutputType
return string

GetProjectOptions() public method

public GetProjectOptions ( string config ) : ProjectOptions
config string
return Microsoft.VisualStudio.Project.ProjectOptions

GetProperty() public method

public GetProperty ( int propId ) : object
propId int
return object

GetServiceProvider() public method

public GetServiceProvider ( ) : IServiceProvider
return IServiceProvider

GetSpecificEditorProperty() public method

public GetSpecificEditorProperty ( string mkDocument, int propid, object &result ) : int
mkDocument string
propid int
result object
return int

GetSpecificEditorType() public method

public GetSpecificEditorType ( string mkDocument, System.Guid &guidEditorType ) : int
mkDocument string
guidEditorType System.Guid
return int

InternalExecCommand() protected method

protected InternalExecCommand ( System.Guid cmdGroup, uint cmdId, uint cmdExecOpt, IntPtr vaIn, IntPtr vaOut, CommandOrigin commandOrigin ) : int
cmdGroup System.Guid
cmdId uint
cmdExecOpt uint
vaIn System.IntPtr
vaOut System.IntPtr
commandOrigin CommandOrigin
return int

IsCodeFile() public method

Evaluates if a file is an Nemerle code file based on is extension
public IsCodeFile ( string strFileName ) : bool
strFileName string The filename to be evaluated
return bool

IsEmbeddedResource() public method

public IsEmbeddedResource ( string strFileName ) : bool
strFileName string
return bool

IsItemTypeFileType() protected method

protected IsItemTypeFileType ( string type ) : bool
type string
return bool

Load() public method

public Load ( string filename, string location, string name, uint flags, System.Guid &iidProject, int &canceled ) : void
filename string
location string
name string
flags uint
iidProject System.Guid
canceled int
return void

NemerleProjectNode() public method

public NemerleProjectNode ( NemerlePackage pkg ) : System
pkg NemerlePackage
return System

OnHandleConfigurationRelatedGlobalProperties() protected method

protected OnHandleConfigurationRelatedGlobalProperties ( object sender, ActiveConfigurationChangedEventArgs eventArgs ) : void
sender object
eventArgs Microsoft.VisualStudio.Project.ActiveConfigurationChangedEventArgs
return void

OpenItem() public method

public OpenItem ( uint itemId, System.Guid &logicalView, IntPtr punkDocDataExisting, IVsWindowFrame &frame ) : int
itemId uint
logicalView System.Guid
punkDocDataExisting System.IntPtr
frame IVsWindowFrame
return int

PrepareBuild() public method

public PrepareBuild ( string config, bool cleanBuild ) : void
config string
cleanBuild bool
return void

ProcessFiles() protected method

Loads file items from the project file into the hierarchy.
protected ProcessFiles ( ) : void
return void

ProcessFolders() protected method

protected ProcessFolders ( ) : void
return void

ProcessReferences() protected method

protected ProcessReferences ( ) : void
return void

SetOutputLogger() protected method

protected SetOutputLogger ( IVsOutputWindowPane output ) : void
output IVsOutputWindowPane
return void

SetSite() public method

public SetSite ( Microsoft site ) : int
site Microsoft
return int

SetSpecificEditorProperty() public method

public SetSpecificEditorProperty ( string mkDocument, int propid, object value ) : int
mkDocument string
propid int
value object
return int

ShowAllFiles() protected method

Enables / Disables the ShowAllFileMode.
protected ShowAllFiles ( ) : int
return int