C# 클래스 VsTeXProject.VisualStudio.Project.ProjectNode

상속: HierarchyNode, IVsGetCfgProvider, IVsProject3, IVsAggregatableProject, IVsProjectFlavorCfgProvider, IPersistFileFormat, IVsProjectBuildSystem, IVsBuildPropertyStorage, IVsComponentUser, IVsDependencyProvider, IVsSccProject2, IBuildDependencyUpdate, IProjectEventsListener, IProjectEventsProvider, IReferenceContainerProvider, IVsProjectSpecialFiles, IVsProjectUpgrade, IVsDesignTimeAssemblyResolution, IVsSetTargetFrameworkWorkerCallback
파일 보기 프로젝트 열기: mimura1133/vstex 1 사용 예제들

Private Properties

프로퍼티 타입 설명
AddCATIDMapping void
AddDependentFileNodeToNode HierarchyNode
AddFileNodeToNode HierarchyNode
AddFileToMsBuild ProjectElement
AddFilesFromProjectReferences bool
AddFolderToMsBuild ProjectElement
AddIndependentFileNode HierarchyNode
AddItemWithSpecific int
Build MSBuildResult
BuildAsync void
BuildPrelude bool
CleanAndFlushClipboard void
CleanupSelectionDataObject void
CleanupSelectionDataObject void
ClonePropertyGroup Microsoft.Build.Construction.ProjectPropertyGroupElement
CloseAllNodes void
CreateMsBuildFileItem ProjectElement
EndBuild void
GetAssemblyName string
GetBaseDirectoryForAddingFiles string
GetBoolAttr bool
GetBoolAttr bool
GetCATIDForType System.Guid
GetComponentPickerDirectories string
GetItemParentNode HierarchyNode
GetMsBuildProperty Microsoft.Build.Execution.ProjectPropertyInstance
GetNestedProjectForHierarchy NestedProjectNode
GetOutputPath string
GetProjectExtensions Microsoft.Build.Construction.ProjectExtensionsElement
GetProjectOptions ProjectOptions
IPersistFileFormat int
IVsBuildPropertyStorage int
IVsBuildPropertyStorage int
IVsBuildPropertyStorage int
IVsProjectFlavorCfgProvider int
InitSccInfo void
Initialize void
InvokeMsBuild MSBuildResult
IsFrameworkOnMachine bool
Load void
OnAfterProjectOpen void
OnHandleConfigurationRelatedGlobalProperties void
PackageSelectionData IntPtr
PackageSelectionDataObject DataObject
PerformTargetFrameworkCheck bool
PersistXMLFragments void
ProcessSelectionDataObject DropDataType
QueryDropDataType DropDataType
QueryDropEffect DropEffect
QueryEditProjectFile bool
RaiseProjectPropertyChanged void
RegisterSccProject void
RunWizard VSADDRESULT
SetBuildProject void
SetProjectExtensions void
SetProjectGuidFromProjectFile void
SetSccSettings bool
SetupProjectGlobalPropertiesThatAllProjectSystemsMustSet void
ShowRetargetingDialog bool
TryBeginBuild bool
UnRegisterProject void
VerifySubFolderExists FolderNode
WrapXmlFragment XmlElement

공개 메소드들

메소드 설명
AddBuildDependency ( IVsBuildDependency dependency ) : void
AddComponent ( VSADDCOMPOPERATION dwAddCompOperation, uint cComponents, IntPtr rgpcsdComponents, IntPtr 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

Called to add a file to the project from a template. Override to do it yourself if you want to customize the file

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

Override this method if you want to modify the behavior of the Add Reference dialog By example you could change which pages are visible and which is visible by default.

Build ( string target ) : MSBuildResult

Overloaded method. Invokes MSBuild using the default configuration and does without logging on the output window pane.

Build ( string target, IVsOutputWindowPane output ) : MSBuildResult

Overloaded method. Invokes MSBuild using the default configuration.

Build ( string config, IVsOutputWindowPane output, string target ) : MSBuildResult

Overloaded method to invoke MSBuild

Build ( string config, string target ) : MSBuildResult

Overloaded method to invoke MSBuild. Does not log build results to the output window pane.

BuildTarget ( string targetName, bool &success ) : int
CallMSBuild ( string target ) : MSBuildResult

Calls MSBuild if it is not suspended. Does not log and uses current configuration. If it is suspended then it will remeber to call when msbuild is resumed.

CallMSBuild ( string target, IVsOutputWindowPane output ) : MSBuildResult

Calls MSBuild if it is not suspended. Uses current configuration. If it is suspended then it will remeber to call when msbuild is resumed.

CallMSBuild ( string config, IVsOutputWindowPane output, string target ) : MSBuildResult

Calls MSBuild if it is not suspended. If it is suspended then it will remember to call when msbuild is resumed.

CallMSBuild ( string config, string target ) : MSBuildResult

Overloaded method. Calls MSBuild if it is not suspended. Does not log on the outputwindow. If it is suspended then it will remeber to call when msbuild is resumed.

CancelBatchEdit ( ) : int
Close ( ) : int

Closes the project node.

CreateDependentFileNode ( ProjectElement item ) : DependentFileNode

Create dependent file node based on an msbuild item

CreateDependentFileNode ( string file ) : DependentFileNode

Create a dependent file node based on a string.

CreateFileNode ( ProjectElement item ) : FileNode

Create a file node based on an msbuild item.

CreateFileNode ( string file ) : FileNode

Create a file node based on a string.

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.

CreateProjectOptions ( ) : ProjectOptions

Override this method if you have your own project specific subclass of ProjectOptions

DragEnter ( Microsoft.VisualStudio.OLE.Interop.IDataObject pDataObject, uint grfKeyState, uint itemid, uint &pdwEffect ) : int

Called as soon as the mouse drags an item over a new hierarchy or hierarchy window

DragLeave ( ) : int

Called when one or more items are dragged out of the hierarchy or hierarchy window, or when the drag-and-drop operation is cancelled or completed.

DragOver ( uint grfKeyState, uint itemid, uint &pdwEffect ) : int

Called when one or more items are dragged over the target hierarchy or hierarchy window.

Drop ( Microsoft.VisualStudio.OLE.Interop.IDataObject pDataObject, uint grfKeyState, uint itemid, uint &pdwEffect ) : int

Called when one or more items are dropped into the target hierarchy or hierarchy window when the mouse button is released.

EndBatchEdit ( ) : int
EnumDependencies ( IVsEnumDependencies &enumDependencies ) : int
GenerateUniqueItemName ( uint itemIdLoc, string ext, string suggestedRoot, string &itemName ) : int

for now used by add folder. Called on the ROOT, as only the project should need to implement this. for folders, called with parent folder, blank extension and blank suggested root

GetAggregateProjectTypeGuids ( string &projectTypeGuids ) : int

Retrieve the list of project GUIDs that are aggregated together to make this project.

GetAssemblyName ( string config ) : string

Get the assembly name for a give configuration

GetAutomationObject ( ) : object

Gets the automation object for the project node.

GetBuildSystemKind ( uint &kind ) : int

Used to determine the kind of build system, in VS 2005 there's only one defined kind: MSBuild

GetCfgProvider ( IVsCfgProvider &p ) : int
GetClassID ( Guid &clsid ) : int
GetCompiler ( ) : ICodeCompiler

Returns the Compiler associated to the project

GetCurFile ( string &name, uint &formatIndex ) : int
GetDropInfo ( uint &pdwOKEffects, Microsoft.VisualStudio.OLE.Interop.IDataObject &ppDataObject, IDropSource &ppDropSource ) : int

Returns information about one or more of the items being dragged

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
GetGuidProperty ( int propid, Guid &guid ) : int

Gets the GUID value of the node.

GetInner ( ) : HierarchyNode

Get the inner object of an aggregated hierarchy

GetItemContext ( uint itemId, Microsoft.VisualStudio.OLE.Interop.IServiceProvider &psp ) : int
GetMkDocument ( uint itemId, string &mkDoc ) : int

Callback from the additem dialog. Deals with adding new and existing items

GetMkDocument ( ) : string

Gets the moniker for the project node. That is the full path of the project file.

GetOutputAssembly ( string config ) : string

Get output assembly for a specific configuration name

GetOutputPath ( string config ) : string

Get the output path for a specific configuration name

GetProjectElement ( Microsoft.Build.Evaluation item ) : ProjectElement

This method returns new project element based on existing MSBuild item. It does not modify/add project/build hierarchy at all.

GetProjectProperty ( string propertyName ) : string

Get value of Project property

GetProjectProperty ( string propertyName, bool resetCache ) : string

Return the value of a project property

GetProjectPropertyUnevaluated ( string propertyName ) : string

Gets the unevaluated value of a project property.

GetProperty ( int propId ) : object

Gets the properties of the project node.

GetReferenceContainer ( ) : IReferenceContainer

Returns the reference container node.

GetSccFiles ( uint itemid, CALPOLESTR stringsOut, CADWORD flagsOut ) : int

This method is called to determine which files should be placed under source control for a given VSITEMID within this hierarchy.

GetSccSpecialFiles ( uint itemid, string sccFile, CALPOLESTR stringsOut, CADWORD flagsOut ) : int

This method is called to discover special (hidden files) associated with a given VSITEMID within this hierarchy.

This method is called to discover any special or hidden files associated with an item in the project hierarchy. It is called when GetSccFiles returns with the SFF_HasSpecialFiles flag set for any of the files associated with the node.

GetTargetFramework ( string &ppTargetFramework ) : int
InitNew ( uint formatIndex ) : int
InitializeForOuter ( string filename, string location, string name, uint flags, Guid &iid, IntPtr &projectPointer, int &canceled ) : int

This is where the initialization occurs.

IsCodeFile ( string fileName ) : bool

Determines whether a file is a code file.

IsDirty ( int &isDirty ) : int
IsDocumentInProject ( string mkDoc, int &found, VSDOCUMENTPRIORITY pri, uint &itemId ) : int
IsEmbeddedResource ( string fileName ) : bool

Determines whether the given file is a resource file (resx file).

Load ( string fileName, uint mode, int readOnly ) : int
NodeFromItemId ( uint itemId ) : HierarchyNode

Get Node from ItemID.

NodeHasDesigner ( string itemPath ) : bool

Defines if Node has Designer. By default we do not support designers for nodes

OnAggregationComplete ( ) : int

This is called after the project is done initializing the different layer of the aggregations

OnBeforeDropNotify ( Microsoft.VisualStudio.OLE.Interop.IDataObject o, uint dwEffect, int &fCancelDrop ) : int

Allows the drag source to prompt to save unsaved items being dropped. Notifies the source hierarchy that information dragged from it is about to be dropped on a target. This method is called immediately after the mouse button is released on a drop.

OnClear ( int wasCut ) : int

Called when your cut/copied operation is canceled

OnDropNotify ( int fDropped, uint dwEffects ) : int

Notifies clients that the dragged item was dropped.

OnOpenItem ( string fullPathToSourceFile ) : void

Called when the project opens an editor window for the given file

OnPaste ( int wasCut, uint dropEffect ) : int

Called after your cut/copied items has been pasted

OnTargetFrameworkMonikerChanged ( ProjectOptions options, FrameworkName currentTargetFramework, FrameworkName newTargetFramework ) : void
OpenDependency ( string szDependencyCanonicalName, IVsDependency &dependency ) : int
OpenItem ( uint itemId, Guid &logicalView, IntPtr punkDocDataExisting, IVsWindowFrame &frame ) : int
OpenItemWithSpecific ( uint itemId, uint editorFlags, Guid &editorType, string physicalView, Guid &logicalView, IntPtr docDataExisting, IVsWindowFrame &frame ) : int
PrepareBuild ( string config, bool cleanBuild ) : void

This is called from the main thread before the background build starts. cleanBuild is not part of the vsopts, but passed down as the callpath is differently PrepareBuild mainly creates directories and cleans house if cleanBuild is true

Remove ( bool removeFromStorage ) : void

Removes items from the hierarchy.

RemoveBuildDependency ( IVsBuildDependency dependency ) : void
RemoveItem ( uint reserved, uint itemId, int &result ) : int
ReopenItem ( uint itemId, Guid &editorType, string physicalView, Guid &logicalView, IntPtr docDataExisting, IVsWindowFrame &frame ) : int
ResolveAssemblyPathInTargetFx ( string prgAssemblySpecs, uint cAssembliesToResolve, VsResolvedAssemblyPath prgResolvedAssemblyPaths, uint &pcResolvedAssemblyPaths ) : int
ResumeMSBuild ( string target ) : void

Resumes MSBuild.

ResumeMSBuild ( string config, IVsOutputWindowPane output, string target ) : void

Resumes MSBuild.

ResumeMSBuild ( string config, string target ) : void

Resumes MSBuild.

Save ( string fileToBeSaved, int remember, uint formatIndex ) : int
SaveCompleted ( string filename ) : int
SccGlyphChanged ( int affectedNodes, uint itemidAffectedNodes, VsStateIcon newGlyphs, uint newSccStatus ) : int

This method is called by the source control portion of the environment to inform the project of changes to the source control glyph on various nodes.

SetAggregateProjectTypeGuids ( string projectTypeGuids ) : int

Set the list of GUIDs that are aggregated together to create this project.

SetEditLabel ( string label ) : int

Renames the project node.

SetGuidProperty ( int propid, Guid &guid ) : int

Sets Guid properties for the project node.

SetHostObject ( string targetName, string taskName, object hostObject ) : int
SetInnerProject ( object innerProject ) : int

We are always the inner most part of the aggregation and as such we don't support setting an inner project

SetProjectFileDirty ( bool value ) : void

Set dirty state of project

SetProjectProperty ( string propertyName, string propertyValue ) : void

Set value of project property

SetProperty ( int propid, object value ) : int

Sets the properties for the project node.

SetSccLocation ( string sccProjectName, string sccAuxPath, string sccLocalPath, string sccProvider ) : int

This method is called by the source control portion of the environment when a project is initially added to source control, or to change some of the project's settings.

SetSite ( Microsoft.VisualStudio.OLE.Interop.IServiceProvider site ) : int

Sets the service provider from which to access the services.

StartBatchEdit ( ) : int
SuspendMSBuild ( ) : void

Suspends MSBuild

TransferItem ( string oldMkDoc, string newMkDoc, IVsWindowFrame frame ) : int

Implements IVsProject3::TransferItem This function is called when an open miscellaneous file is being transferred to our project. The sequence is for the shell to call AddItemWithSpecific and then use TransferItem to transfer the open document to our project.

UpdateTargetFramework ( IVsHierarchy pHier, string currentTargetFramework, string newTargetFramework ) : int
UpgradeProject ( uint grfUpgradeFlags ) : int

보호된 메소드들

메소드 설명
AddDependentFileNode ( MSBuild.ProjectItem>.IDictionary subitems, string key ) : HierarchyNode

This add methos adds the "key" item to the hierarchy, potentially adding other subitems in the process This method may recurse if the parent is an other subitem

If the parent node was found we add the dependent item to it otherwise we add the item ignoring the "DependentUpon" metatdata

AddFolderFromOtherProject ( string folderToAdd, HierarchyNode targetNode ) : void

This is used to recursively add a folder from an other project. Note that while we copy the folder content completely, we only add to the project items which are part of the source project.

AddNewFileNodeToHierarchy ( HierarchyNode parentNode, string fileName ) : void

Adds a new file node to the hierarchy.

AddNodeIfTargetExistInStorage ( HierarchyNode parentNode, string name, string targetPath ) : HierarchyNode

Add an existing item (file/folder) to the project if it already exist in our storage.

AddWebReference ( ) : int

Handles the Add web reference command.

AllowPasteCommand ( ) : bool

Determines if the paste command should be allowed.

CanDeleteItem ( __VSDELETEITEMOPERATION deleteOperation ) : bool

Get the boolean value for the deletion of a project item

CanOverwriteExistingItem ( string originalFileName, string computedNewFileName ) : int

Determines whether an item can be owerwritten in the hierarchy.

CanTargetNodeAcceptDrop ( uint itemId ) : bool

Determines if a node can accept drop opertaion.

CleanProject ( ) : int

Handles the clean project command.

CompareNodes ( HierarchyNode node1, HierarchyNode node2 ) : int

Used to sort nodes in the hierarchy.

CopyToClipboard ( ) : int

Handle the Copy operation to the clipboard

CreateConfigProvider ( ) : ConfigProvider

Factory method for configuration provider

CreateFolderNode ( string path ) : FolderNode

Create FolderNode from Path

CreateFolderNode ( string path, ProjectElement element ) : FolderNode

To support virtual folders, override this method to return your own folder nodes

CreatePropertiesObject ( ) : NodeProperties
CreateReferenceContainerNode ( ) : ReferenceContainerNode

Factory method for reference container node

CutToClipboard ( ) : int

Handle the Cut operation to the clipboard

Dispose ( bool disposing ) : void

Disposes the project node object.

DoMSBuildSubmission ( BuildKind buildKind, string target, string>.Action uiThreadCallback ) : Microsoft.Build.Execution.BuildSubmission

Start MSBuild build submission

ExecCommandOnNode ( System.Guid cmdGroup, uint cmd, uint nCmdexecopt, IntPtr pvaIn, IntPtr pvaOut ) : int

Handles command execution.

FilterItemTypeToBeAddedToHierarchy ( string itemType ) : bool

Filter items that should not be processed as file items. Example: Folders and References.

FlushBuildLoggerContent ( ) : void

Flush any remaining content from build logger. This method is called as part of the callback method passed to the buildsubmission during async build so that results can be printed the the build is finished.

GetConfigurationDependentPropertyPages ( ) : Guid[]

Returns a list of Guids of the configuration dependent property pages. It is called by the GetProperty for VSHPROPID_CfgPropertyPagesCLSIDList property.

GetConfigurationIndependentPropertyPages ( ) : Guid[]

List of Guids of the config independent property pages. It is called by the GetProperty for VSHPROPID_PropertyPagesCLSIDList property.

GetDocumentManager ( ) : DocumentManager

Returns a specific Document manager to handle opening and closing of the Project(Application) Designer if projectdesigner is supported.

GetOutputGroupDescription ( string canonicalName ) : string

Get the description of the given output group.

GetOutputGroupDisplayName ( string canonicalName ) : string

Get the display name of the given output group.

GetOutputGroupNames ( ) : string>>.IList

This is the list of output groups that the configuration object should provide. The first string is the name of the group. The second string is the target name (MSBuild) for that group. To add/remove OutputGroups, simply override this method and edit the list. To get nice display names and description for your groups, override: - GetOutputGroupDisplayName - GetOutputGroupDescription

GetPriorityProjectDesignerPages ( ) : Guid[]

An ordered list of guids of the prefered property pages. See __VSHPROPID.VSHPROPID_PriorityPropertyPagesCLSIDList

GetSelectedNodes ( ) : IList

Gets the list of selected HierarchyNode objects

InitializeProjectProperties ( ) : void

Initialize common project properties with default value if they are empty

The following common project properties are defaulted to projectName (if empty): AssemblyName, Name and RootNamespace. If the project filename is not set then no properties are set

IsCurrentStateASuppressCommandsMode ( ) : bool

Defines whther the current mode of the project is in a supress command mode.

IsFlavorDirty ( ) : int
IsItemTypeFileType ( string type ) : bool

Called by the project to know if the item is a file (that is part of the project) or an intermediate file used by the MSBuild tasks/targets Override this method if your project has more types or different ones

LoadNonBuildInformation ( ) : void

For flavored projects which implement IPersistXMLFragment, load the information now

LoadXmlFragment ( IPersistXMLFragment persistXmlFragment, string configName ) : void

Initialize an object with an XML fragment.

OverwriteExistingItem ( HierarchyNode existingNode ) : void

Handle owerwriting of an existing item in the hierarchy.

PasteFromClipboard ( HierarchyNode targetNode ) : int

Handle the Paste operation to a targetNode

ProcessDependentFileNodes ( IList subitemsKeys, MSBuild.ProjectItem>.Dictionary subitems ) : void

Processes dependent filenodes from list of subitems. Multi level supported, but not circular dependencies.

ProcessFiles ( ) : void

Loads file items from the project file into the hierarchy.

ProcessFolders ( ) : void

Loads folders from the project file into the hierarchy.

ProcessReferences ( ) : void

Loads reference items from the project file into the hierarchy.

ProjectNode ( ) : System
QueryStatusOnNode ( Guid cmdGroup, uint cmd, IntPtr pCmdText, QueryStatusResult &result ) : int

Handles command status on the project node. If a command cannot be handled then the base should be called.

RegisterClipboardNotifications ( bool register ) : void

Register/Unregister for Clipboard events for the UiHierarchyWindow (solution explorer)

Reload ( ) : void

Reload project from project file

RenameProjectFile ( string newFile ) : void

Renames the project file

SaveAs ( string newFileName ) : int

Saves the project file on a new name.

SaveMSBuildProjectFileAs ( string newFileName ) : void

Saves project file related information to the new file name. It also calls msbuild API to save the project file. It is called by the SaveAs method and the SetEditLabel before the project file rename related events are triggered. An implementer can override this method to provide specialized semantics on how the project file is renamed in the msbuild file.

SetBuildConfigurationProperties ( string config ) : void

Set configuration properties for a specific configuration

SetConfiguration ( string config ) : void

Set the configuration property in MSBuild. This does not get persisted and is used to evaluate msbuild conditions which are based on the $(Configuration) property.

SetCurrentConfiguration ( ) : void

Set the configuration in MSBuild. This does not get persisted and is used to evaluate msbuild conditions which are based on the $(Configuration) property.

SetOutputLogger ( IVsOutputWindowPane output ) : void

Associate window output pane to the build logger

ShowAllFiles ( ) : int

Handles the shows all objects command.

UnloadProject ( ) : int

Unloads the project.

UpdateSccStateIcons ( ) : void

Recursevily walks the hierarchy nodes and redraws the state icons

WalkSourceProjectAndAdd ( IVsHierarchy sourceHierarchy, uint itemId, HierarchyNode targetNode, bool addSiblings ) : void

Recursive method that walk a hierarchy and add items it find to our project. Note that this is meant as an helper to the Copy&Paste/Drag&Drop functionality.

비공개 메소드들

메소드 설명
AddCATIDMapping ( Type type, System.Guid catid ) : void
AddDependentFileNodeToNode ( Microsoft.Build.Evaluation item, HierarchyNode parentNode ) : HierarchyNode

Add a dependent file node to the hierarchy

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

Add a file node to the hierarchy

AddFileToMsBuild ( string file ) : ProjectElement
AddFilesFromProjectReferences ( HierarchyNode targetNode, string projectReferences ) : bool

Moves files from one part of our project to another.

AddFolderToMsBuild ( string folder ) : ProjectElement
AddIndependentFileNode ( Microsoft.Build.Evaluation item ) : HierarchyNode

Add an item to the hierarchy based on the item path

AddItemWithSpecific ( uint itemIdLoc, VSADDITEMOPERATION op, string itemName, uint filesToOpen, string files, IntPtr dlgOwner, uint editorFlags, System.Guid &editorType, string physicalView, System.Guid &logicalView, VSADDRESULT result ) : int
Build ( uint vsopts, string config, IVsOutputWindowPane output, string target ) : MSBuildResult
BuildAsync ( uint vsopts, string config, IVsOutputWindowPane output, string target, string>.Action uiThreadCallback ) : void
BuildPrelude ( IVsOutputWindowPane output ) : bool

Helper for sharing common code between Build() and BuildAsync()

CleanAndFlushClipboard ( ) : void

Empties all the data structures added to the clipboard and flushes the clipboard.

CleanupSelectionDataObject ( bool dropped, bool cut, bool moved ) : void
CleanupSelectionDataObject ( bool dropped, bool cut, bool moved, bool justCleanup ) : void

After a drop or paste, will use the dwEffects to determine whether we need to clean up the source nodes or not. If justCleanup is set, it only does the cleanup work.

ClonePropertyGroup ( Microsoft.Build.Construction group ) : Microsoft.Build.Construction.ProjectPropertyGroupElement

For internal use only. This creates a copy of an existing configuration and add it to the project. Caller should change the condition on the PropertyGroup. If derived class want to accomplish this, they should call ConfigProvider.AddCfgsOfCfgName() It is expected that in the future MSBuild will have support for this so we don't have to do it manually.

CloseAllNodes ( HierarchyNode node ) : void

Recusively parses the tree and closes all nodes.

CreateMsBuildFileItem ( string file, string itemType ) : ProjectElement
EndBuild ( Microsoft.Build.Execution submission, bool designTime, bool requiresUIThread = false ) : void

Lets Visual Studio know that we're done with our design-time build so others can use the build manager.

This method must be called on the UI thread.

GetAssemblyName ( Microsoft.Build.Execution properties ) : string
GetBaseDirectoryForAddingFiles ( HierarchyNode nodeToAddFile ) : string

Given a node determines what is the directory that can accept files. If the node is a FoldeNode than it is the Url of the Folder. If the node is a ProjectNode it is the project folder. Otherwise (such as FileNode subitem) it delegate the resolution to the parent node.

GetBoolAttr ( Microsoft.Build.Execution properties, string name ) : bool
GetBoolAttr ( string config, string name ) : bool
GetCATIDForType ( Type type ) : System.Guid
GetComponentPickerDirectories ( ) : string
GetItemParentNode ( Microsoft.Build.Evaluation item ) : HierarchyNode

Get the parent node of an msbuild item

GetMsBuildProperty ( string propertyName, bool resetCache ) : Microsoft.Build.Execution.ProjectPropertyInstance
GetNestedProjectForHierarchy ( IVsHierarchy hierarchy ) : NestedProjectNode

Checks whether a hierarchy is a nested project.

GetOutputPath ( Microsoft.Build.Execution properties ) : string
GetProjectExtensions ( ) : Microsoft.Build.Construction.ProjectExtensionsElement

Get the project extensions

GetProjectOptions ( string config = null ) : ProjectOptions
IPersistFileFormat ( Guid &clsid ) : int
IVsBuildPropertyStorage ( string propertyName, string configName, uint storage ) : int

Delete a property In our case this simply mean defining it as null

IVsBuildPropertyStorage ( string propertyName, string configName, uint storage, string &propertyValue ) : int

Get the value of the property in the project file

IVsBuildPropertyStorage ( uint item, string attributeName, string &attributeValue ) : int

Get the property of an item

IVsProjectFlavorCfgProvider ( IVsCfg pBaseProjectCfg, IVsProjectFlavorCfg &ppFlavorCfg ) : int
InitSccInfo ( ) : void

Sets the scc info from the project file.

Initialize ( ) : void

Initialize projectNode

InvokeMsBuild ( string target ) : MSBuildResult
IsFrameworkOnMachine ( ) : bool
Load ( string fileName, string location, string name, uint flags, Guid &iidProject, int &canceled ) : void
OnAfterProjectOpen ( object sender, AfterProjectFileOpenedEventArgs e ) : void
OnHandleConfigurationRelatedGlobalProperties ( object sender, ActiveConfigurationChangedEventArgs eventArgs ) : void
PackageSelectionData ( StringBuilder sb, bool addEndFormatDelimiter ) : IntPtr
PackageSelectionDataObject ( bool cutHighlightItems ) : DataObject

Returns a dataobject from selected nodes

PerformTargetFrameworkCheck ( ) : bool
PersistXMLFragments ( ) : void
ProcessSelectionDataObject ( Microsoft.VisualStudio.OLE.Interop.IDataObject dataObject, HierarchyNode targetNode ) : DropDataType

Process dataobject from Drag/Drop/Cut/Copy/Paste operation

The targetNode is set if the method is called from a drop operation, otherwise it is null

QueryDropDataType ( Microsoft.VisualStudio.OLE.Interop.IDataObject pDataObject ) : DropDataType

Get the dropdatatype from the dataobject

QueryDropEffect ( DropDataType dropDataType, uint grfKeyState ) : DropEffect

Returns the drop effect.

// A directory based project should perform as follow: NO MODIFIER - COPY if not from current hierarchy, - MOVE if from current hierarchy SHIFT DRAG - MOVE CTRL DRAG - COPY CTRL-SHIFT DRAG - NO DROP (used for reference based projects only)

QueryEditProjectFile ( bool suppressUI ) : bool

Verify if the file can be written to. Return false if the file is read only and/or not checked out and the user did not give permission to change it. Note that exact behavior can also be affected based on the SCC settings under Tools->Options.

RaiseProjectPropertyChanged ( string propertyName, string oldValue, string newValue ) : void
RegisterSccProject ( ) : void
RunWizard ( HierarchyNode parentNode, string itemName, string wizardToRun, IntPtr dlgOwner ) : VSADDRESULT
SetBuildProject ( Microsoft.Build.Evaluation project ) : void

Set the build project with the new project instance value

SetProjectExtensions ( string id, string xmlText ) : void

Set the xmlText as a project extension element with the id passed.

SetProjectGuidFromProjectFile ( ) : void

Sets the project guid from the project file. If no guid is found a new one is created and assigne for the instance project guid.

SetSccSettings ( string sccProjectName, string sccLocalPath, string sccAuxPath, string sccProvider ) : bool

Updates our scc project settings.

SetupProjectGlobalPropertiesThatAllProjectSystemsMustSet ( ) : void

Setup the global properties for project instance.

ShowRetargetingDialog ( ) : bool

TryBeginBuild ( bool designTime, bool requiresUIThread = false ) : bool

Attempts to lock in the privilege of running a build in Visual Studio.

This method must be called on the UI thread.

UnRegisterProject ( ) : void
VerifySubFolderExists ( string path, HierarchyNode parent ) : FolderNode
WrapXmlFragment ( XmlDocument document, XmlElement root, Guid flavor, string configuration, string fragment ) : XmlElement

메소드 상세

AddBuildDependency() 공개 메소드

public AddBuildDependency ( IVsBuildDependency dependency ) : void
dependency IVsBuildDependency
리턴 void

AddComponent() 공개 메소드

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, IntPtr rgpcsdComponents, IntPtr hwndDialog, VSADDCOMPRESULT pResult ) : int
dwAddCompOperation VSADDCOMPOPERATION The component operation to be performed.
cComponents uint Number of components to be added
rgpcsdComponents System.IntPtr array of component selector data
hwndDialog System.IntPtr Handle to the component picker dialog
pResult VSADDCOMPRESULT Result to be returned to the caller
리턴 int

AddDependentFileNode() 보호된 메소드

This add methos adds the "key" item to the hierarchy, potentially adding other subitems in the process This method may recurse if the parent is an other subitem
If the parent node was found we add the dependent item to it otherwise we add the item ignoring the "DependentUpon" metatdata
protected AddDependentFileNode ( MSBuild.ProjectItem>.IDictionary subitems, string key ) : HierarchyNode
subitems MSBuild.ProjectItem>.IDictionary List of subitems not yet added to the hierarchy
key string Key to retrieve the target item from the subitems list
리턴 HierarchyNode

AddFileFromTemplate() 공개 메소드

Called to add a file to the project from a template. Override to do it yourself if you want to customize the file
public AddFileFromTemplate ( string source, string target ) : void
source string Full path of template file
target string Full path of file once added to the project
리턴 void

AddFolderFromOtherProject() 보호된 메소드

This is used to recursively add a folder from an other project. Note that while we copy the folder content completely, we only add to the project items which are part of the source project.
protected AddFolderFromOtherProject ( string folderToAdd, HierarchyNode targetNode ) : void
folderToAdd string Project reference (from data object) using the format: {Guid}|project|folderPath
targetNode HierarchyNode Node to add the new folder to
리턴 void

AddItem() 공개 메소드

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
리턴 int

AddNewFileNodeToHierarchy() 보호된 메소드

Adds a new file node to the hierarchy.
protected AddNewFileNodeToHierarchy ( HierarchyNode parentNode, string fileName ) : void
parentNode HierarchyNode The parent of the new fileNode
fileName string The file name
리턴 void

AddNodeIfTargetExistInStorage() 보호된 메소드

Add an existing item (file/folder) to the project if it already exist in our storage.
protected AddNodeIfTargetExistInStorage ( HierarchyNode parentNode, string name, string targetPath ) : HierarchyNode
parentNode HierarchyNode Node to that this item to
name string Name of the item being added
targetPath string Path of the item being added
리턴 HierarchyNode

AddProjectReference() 공개 메소드

Override this method if you want to modify the behavior of the Add Reference dialog By example you could change which pages are visible and which is visible by default.
public AddProjectReference ( ) : int
리턴 int

AddWebReference() 보호된 메소드

Handles the Add web reference command.
protected AddWebReference ( ) : int
리턴 int

AllowPasteCommand() 보호된 메소드

Determines if the paste command should be allowed.
protected AllowPasteCommand ( ) : bool
리턴 bool

Build() 공개 메소드

Overloaded method. Invokes MSBuild using the default configuration and does without logging on the output window pane.
public Build ( string target ) : MSBuildResult
target string
리턴 MSBuildResult

Build() 공개 메소드

Overloaded method. Invokes MSBuild using the default configuration.
public Build ( string target, IVsOutputWindowPane output ) : MSBuildResult
target string
output IVsOutputWindowPane
리턴 MSBuildResult

Build() 공개 메소드

Overloaded method to invoke MSBuild
public Build ( string config, IVsOutputWindowPane output, string target ) : MSBuildResult
config string
output IVsOutputWindowPane
target string
리턴 MSBuildResult

Build() 공개 메소드

Overloaded method to invoke MSBuild. Does not log build results to the output window pane.
public Build ( string config, string target ) : MSBuildResult
config string
target string
리턴 MSBuildResult

BuildTarget() 공개 메소드

public BuildTarget ( string targetName, bool &success ) : int
targetName string
success bool
리턴 int

CallMSBuild() 공개 메소드

Calls MSBuild if it is not suspended. Does not log and uses current configuration. If it is suspended then it will remeber to call when msbuild is resumed.
public CallMSBuild ( string target ) : MSBuildResult
target string
리턴 MSBuildResult

CallMSBuild() 공개 메소드

Calls MSBuild if it is not suspended. Uses current configuration. If it is suspended then it will remeber to call when msbuild is resumed.
public CallMSBuild ( string target, IVsOutputWindowPane output ) : MSBuildResult
target string
output IVsOutputWindowPane
리턴 MSBuildResult

CallMSBuild() 공개 메소드

Calls MSBuild if it is not suspended. If it is suspended then it will remember to call when msbuild is resumed.
public CallMSBuild ( string config, IVsOutputWindowPane output, string target ) : MSBuildResult
config string
output IVsOutputWindowPane
target string
리턴 MSBuildResult

CallMSBuild() 공개 메소드

Overloaded method. Calls MSBuild if it is not suspended. Does not log on the outputwindow. If it is suspended then it will remeber to call when msbuild is resumed.
public CallMSBuild ( string config, string target ) : MSBuildResult
config string
target string
리턴 MSBuildResult

CanDeleteItem() 보호된 메소드

Get the boolean value for the deletion of a project item
protected CanDeleteItem ( __VSDELETEITEMOPERATION deleteOperation ) : bool
deleteOperation __VSDELETEITEMOPERATION /// A flag that specifies the type of delete operation (delete from storage or remove from /// project) ///
리턴 bool

CanOverwriteExistingItem() 보호된 메소드

Determines whether an item can be owerwritten in the hierarchy.
protected CanOverwriteExistingItem ( string originalFileName, string computedNewFileName ) : int
originalFileName string The orginal filname.
computedNewFileName string /// The computed new file name, that will be copied to the project directory or into the /// folder . ///
리턴 int

CanTargetNodeAcceptDrop() 보호된 메소드

Determines if a node can accept drop opertaion.
protected CanTargetNodeAcceptDrop ( uint itemId ) : bool
itemId uint
리턴 bool

CancelBatchEdit() 공개 메소드

public CancelBatchEdit ( ) : int
리턴 int

CleanProject() 보호된 메소드

Handles the clean project command.
protected CleanProject ( ) : int
리턴 int

Close() 공개 메소드

Closes the project node.
public Close ( ) : int
리턴 int

CompareNodes() 보호된 메소드

Used to sort nodes in the hierarchy.
protected CompareNodes ( HierarchyNode node1, HierarchyNode node2 ) : int
node1 HierarchyNode
node2 HierarchyNode
리턴 int

CopyToClipboard() 보호된 메소드

Handle the Copy operation to the clipboard
protected CopyToClipboard ( ) : int
리턴 int

CreateConfigProvider() 보호된 메소드

Factory method for configuration provider
protected CreateConfigProvider ( ) : ConfigProvider
리턴 ConfigProvider

CreateDependentFileNode() 공개 메소드

Create dependent file node based on an msbuild item
public CreateDependentFileNode ( ProjectElement item ) : DependentFileNode
item ProjectElement msbuild item
리턴 DependentFileNode

CreateDependentFileNode() 공개 메소드

Create a dependent file node based on a string.
public CreateDependentFileNode ( string file ) : DependentFileNode
file string filename of the new dependent file node
리턴 DependentFileNode

CreateFileNode() 공개 메소드

Create a file node based on an msbuild item.
public CreateFileNode ( ProjectElement item ) : FileNode
item ProjectElement msbuild item
리턴 FileNode

CreateFileNode() 공개 메소드

Create a file node based on a string.
public CreateFileNode ( string file ) : FileNode
file string filename of the new filenode
리턴 FileNode

CreateFolderNode() 보호된 메소드

Create FolderNode from Path
protected CreateFolderNode ( string path ) : FolderNode
path string Path to folder
리턴 FolderNode

CreateFolderNode() 보호된 메소드

To support virtual folders, override this method to return your own folder nodes
protected CreateFolderNode ( string path, ProjectElement element ) : FolderNode
path string Path to store for this folder
element ProjectElement Element corresponding to the folder
리턴 FolderNode

CreateFolderNodes() 공개 메소드

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
리턴 HierarchyNode

CreateProjectOptions() 공개 메소드

Override this method if you have your own project specific subclass of ProjectOptions
public CreateProjectOptions ( ) : ProjectOptions
리턴 ProjectOptions

CreatePropertiesObject() 보호된 메소드

protected CreatePropertiesObject ( ) : NodeProperties
리턴 NodeProperties

CreateReferenceContainerNode() 보호된 메소드

Factory method for reference container node
protected CreateReferenceContainerNode ( ) : ReferenceContainerNode
리턴 ReferenceContainerNode

CutToClipboard() 보호된 메소드

Handle the Cut operation to the clipboard
protected CutToClipboard ( ) : int
리턴 int

Dispose() 보호된 메소드

Disposes the project node object.
protected Dispose ( bool disposing ) : void
disposing bool Flag determining ehether it was deterministic or non deterministic clean up.
리턴 void

DoMSBuildSubmission() 보호된 메소드

Start MSBuild build submission
protected DoMSBuildSubmission ( BuildKind buildKind, string target, string>.Action uiThreadCallback ) : Microsoft.Build.Execution.BuildSubmission
buildKind BuildKind Is it a Sync or ASync build
target string target to build
uiThreadCallback string>.Action callback to be run UI thread
리턴 Microsoft.Build.Execution.BuildSubmission

DragEnter() 공개 메소드

Called as soon as the mouse drags an item over a new hierarchy or hierarchy window
public DragEnter ( Microsoft.VisualStudio.OLE.Interop.IDataObject pDataObject, uint grfKeyState, uint itemid, uint &pdwEffect ) : int
pDataObject Microsoft.VisualStudio.OLE.Interop.IDataObject reference to interface IDataObject of the item being dragged
grfKeyState uint /// Current state of the keyboard and the mouse modifier keys. See docs for a list of possible /// values ///
itemid uint Item identifier for the item currently being dragged
pdwEffect uint On entry, a pointer to the current DropEffect. On return, must contain the new valid DropEffect
리턴 int

DragLeave() 공개 메소드

Called when one or more items are dragged out of the hierarchy or hierarchy window, or when the drag-and-drop operation is cancelled or completed.
public DragLeave ( ) : int
리턴 int

DragOver() 공개 메소드

Called when one or more items are dragged over the target hierarchy or hierarchy window.
public DragOver ( uint grfKeyState, uint itemid, uint &pdwEffect ) : int
grfKeyState uint /// Current state of the keyboard keys and the mouse modifier buttons. See /// ///
itemid uint Item identifier of the drop data target over which the item is being dragged
pdwEffect uint /// On entry, reference to the value of the pdwEffect parameter of the IVsHierarchy object, identifying all effects /// that the hierarchy supports. /// On return, the pdwEffect parameter must contain one of the effect flags that indicate the result of the drop /// operation. For a list of pwdEffects values, see ///
리턴 int

Drop() 공개 메소드

Called when one or more items are dropped into the target hierarchy or hierarchy window when the mouse button is released.
public Drop ( Microsoft.VisualStudio.OLE.Interop.IDataObject pDataObject, uint grfKeyState, uint itemid, uint &pdwEffect ) : int
pDataObject Microsoft.VisualStudio.OLE.Interop.IDataObject /// Reference to the IDataObject interface on the item being dragged. This data object contains the data being /// transferred in the drag-and-drop operation. /// If the drop occurs, then this data object (item) is incorporated into the target hierarchy or hierarchy window. ///
grfKeyState uint /// Current state of the keyboard and the mouse modifier keys. See /// ///
itemid uint Item identifier of the drop data target over which the item is being dragged
pdwEffect uint /// Visual effects associated with the drag-and drop-operation, such as a cursor, bitmap, and so on. /// The value of dwEffects passed to the source object via the OnDropNotify method is the value of pdwEffects returned /// by the Drop method ///
리턴 int

EndBatchEdit() 공개 메소드

public EndBatchEdit ( ) : int
리턴 int

EnumDependencies() 공개 메소드

public EnumDependencies ( IVsEnumDependencies &enumDependencies ) : int
enumDependencies IVsEnumDependencies
리턴 int

ExecCommandOnNode() 보호된 메소드

Handles command execution.
protected ExecCommandOnNode ( System.Guid cmdGroup, uint cmd, uint nCmdexecopt, IntPtr pvaIn, IntPtr pvaOut ) : int
cmdGroup System.Guid Unique identifier of the command group
cmd uint The command to be executed.
nCmdexecopt uint Values describe how the object should execute the command.
pvaIn System.IntPtr Pointer to a VARIANTARG structure containing input arguments. Can be NULL
pvaOut System.IntPtr VARIANTARG structure to receive command output. Can be NULL.
리턴 int

FilterItemTypeToBeAddedToHierarchy() 보호된 메소드

Filter items that should not be processed as file items. Example: Folders and References.
protected FilterItemTypeToBeAddedToHierarchy ( string itemType ) : bool
itemType string
리턴 bool

FlushBuildLoggerContent() 보호된 메소드

Flush any remaining content from build logger. This method is called as part of the callback method passed to the buildsubmission during async build so that results can be printed the the build is finished.
protected FlushBuildLoggerContent ( ) : void
리턴 void

GenerateUniqueItemName() 공개 메소드

for now used by add folder. Called on the ROOT, as only the project should need to implement this. for folders, called with parent folder, blank extension and blank suggested root
public GenerateUniqueItemName ( uint itemIdLoc, string ext, string suggestedRoot, string &itemName ) : int
itemIdLoc uint
ext string
suggestedRoot string
itemName string
리턴 int

GetAggregateProjectTypeGuids() 공개 메소드

Retrieve the list of project GUIDs that are aggregated together to make this project.
public GetAggregateProjectTypeGuids ( string &projectTypeGuids ) : int
projectTypeGuids string /// Semi colon separated list of Guids. Typically, the last GUID would be the GUID of the /// base project factory ///
리턴 int

GetAssemblyName() 공개 메소드

Get the assembly name for a give configuration
public GetAssemblyName ( string config ) : string
config string the matching configuration in the msbuild file
리턴 string

GetAutomationObject() 공개 메소드

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

GetBuildSystemKind() 공개 메소드

Used to determine the kind of build system, in VS 2005 there's only one defined kind: MSBuild
public GetBuildSystemKind ( uint &kind ) : int
kind uint
리턴 int

GetCfgProvider() 공개 메소드

public GetCfgProvider ( IVsCfgProvider &p ) : int
p IVsCfgProvider
리턴 int

GetClassID() 공개 메소드

public GetClassID ( Guid &clsid ) : int
clsid Guid
리턴 int

GetCompiler() 공개 메소드

Returns the Compiler associated to the project
public GetCompiler ( ) : ICodeCompiler
리턴 ICodeCompiler

GetConfigurationDependentPropertyPages() 보호된 메소드

Returns a list of Guids of the configuration dependent property pages. It is called by the GetProperty for VSHPROPID_CfgPropertyPagesCLSIDList property.
protected GetConfigurationDependentPropertyPages ( ) : Guid[]
리턴 Guid[]

GetConfigurationIndependentPropertyPages() 보호된 메소드

List of Guids of the config independent property pages. It is called by the GetProperty for VSHPROPID_PropertyPagesCLSIDList property.
protected GetConfigurationIndependentPropertyPages ( ) : Guid[]
리턴 Guid[]

GetCurFile() 공개 메소드

public GetCurFile ( string &name, uint &formatIndex ) : int
name string
formatIndex uint
리턴 int

GetDocumentManager() 보호된 메소드

Returns a specific Document manager to handle opening and closing of the Project(Application) Designer if projectdesigner is supported.
protected GetDocumentManager ( ) : DocumentManager
리턴 DocumentManager

GetDropInfo() 공개 메소드

Returns information about one or more of the items being dragged
public GetDropInfo ( uint &pdwOKEffects, Microsoft.VisualStudio.OLE.Interop.IDataObject &ppDataObject, IDropSource &ppDropSource ) : int
pdwOKEffects uint /// Pointer to a DWORD value describing the effects displayed while the item is being dragged, /// such as cursor icons that change during the drag-and-drop operation. /// For example, if the item is dragged over an invalid target point /// (such as the item's original location), the cursor icon changes to a circle with a line through it. /// Similarly, if the item is dragged over a valid target point, the cursor icon changes to a file or folder. ///
ppDataObject Microsoft.VisualStudio.OLE.Interop.IDataObject /// Pointer to the IDataObject interface on the item being dragged. /// This data object contains the data being transferred in the drag-and-drop operation. /// If the drop occurs, then this data object (item) is incorporated into the target hierarchy or hierarchy window. ///
ppDropSource IDropSource Pointer to the IDropSource interface of the item being dragged.
리턴 int

GetFile() 공개 메소드

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.
리턴 int

GetFormatList() 공개 메소드

public GetFormatList ( string &formatlist ) : int
formatlist string
리턴 int

GetGuidProperty() 공개 메소드

Gets the GUID value of the node.
public GetGuidProperty ( int propid, Guid &guid ) : int
propid int A __VSHPROPID or __VSHPROPID2 value of the guid property
guid Guid The guid to return for the property.
리턴 int

GetInner() 공개 메소드

Get the inner object of an aggregated hierarchy
public GetInner ( ) : HierarchyNode
리턴 HierarchyNode

GetItemContext() 공개 메소드

public GetItemContext ( uint itemId, Microsoft.VisualStudio.OLE.Interop.IServiceProvider &psp ) : int
itemId uint
psp Microsoft.VisualStudio.OLE.Interop.IServiceProvider
리턴 int

GetMkDocument() 공개 메소드

Callback from the additem dialog. Deals with adding new and existing items
public GetMkDocument ( uint itemId, string &mkDoc ) : int
itemId uint
mkDoc string
리턴 int

GetMkDocument() 공개 메소드

Gets the moniker for the project node. That is the full path of the project file.
public GetMkDocument ( ) : string
리턴 string

GetOutputAssembly() 공개 메소드

Get output assembly for a specific configuration name
public GetOutputAssembly ( string config ) : string
config string Name of configuration
리턴 string

GetOutputGroupDescription() 보호된 메소드

Get the description of the given output group.
protected GetOutputGroupDescription ( string canonicalName ) : string
canonicalName string Canonical name of the output group
리턴 string

GetOutputGroupDisplayName() 보호된 메소드

Get the display name of the given output group.
protected GetOutputGroupDisplayName ( string canonicalName ) : string
canonicalName string Canonical name of the output group
리턴 string

GetOutputGroupNames() 보호된 메소드

This is the list of output groups that the configuration object should provide. The first string is the name of the group. The second string is the target name (MSBuild) for that group. To add/remove OutputGroups, simply override this method and edit the list. To get nice display names and description for your groups, override: - GetOutputGroupDisplayName - GetOutputGroupDescription
protected GetOutputGroupNames ( ) : string>>.IList
리턴 string>>.IList

GetOutputPath() 공개 메소드

Get the output path for a specific configuration name
public GetOutputPath ( string config ) : string
config string name of configuration
리턴 string

GetPriorityProjectDesignerPages() 보호된 메소드

An ordered list of guids of the prefered property pages. See __VSHPROPID.VSHPROPID_PriorityPropertyPagesCLSIDList
protected GetPriorityProjectDesignerPages ( ) : Guid[]
리턴 Guid[]

GetProjectElement() 공개 메소드

This method returns new project element based on existing MSBuild item. It does not modify/add project/build hierarchy at all.
public GetProjectElement ( Microsoft.Build.Evaluation item ) : ProjectElement
item Microsoft.Build.Evaluation MSBuild item instance
리턴 ProjectElement

GetProjectProperty() 공개 메소드

Get value of Project property
public GetProjectProperty ( string propertyName ) : string
propertyName string Name of Property to retrieve
리턴 string

GetProjectProperty() 공개 메소드

Return the value of a project property
public GetProjectProperty ( string propertyName, bool resetCache ) : string
propertyName string Name of the property to get
resetCache bool True to avoid using the cache
리턴 string

GetProjectPropertyUnevaluated() 공개 메소드

Gets the unevaluated value of a project property.
public GetProjectPropertyUnevaluated ( string propertyName ) : string
propertyName string The name of the property to retrieve.
리턴 string

GetProperty() 공개 메소드

Gets the properties of the project node.
public GetProperty ( int propId ) : object
propId int The __VSHPROPID of the property.
리턴 object

GetReferenceContainer() 공개 메소드

Returns the reference container node.
public GetReferenceContainer ( ) : IReferenceContainer
리턴 IReferenceContainer

GetSccFiles() 공개 메소드

This method is called to determine which files should be placed under source control for a given VSITEMID within this hierarchy.
public GetSccFiles ( uint itemid, CALPOLESTR stringsOut, CADWORD flagsOut ) : int
itemid uint Identifier for the VSITEMID being queried.
stringsOut CALPOLESTR Pointer to an array of CALPOLESTR strings containing the file names for this item.
flagsOut CADWORD /// Pointer to a CADWORD array of flags stored in DWORDs indicating that some of the files have /// special behaviors. ///
리턴 int

GetSccSpecialFiles() 공개 메소드

This method is called to discover special (hidden files) associated with a given VSITEMID within this hierarchy.
This method is called to discover any special or hidden files associated with an item in the project hierarchy. It is called when GetSccFiles returns with the SFF_HasSpecialFiles flag set for any of the files associated with the node.
public GetSccSpecialFiles ( uint itemid, string sccFile, CALPOLESTR stringsOut, CADWORD flagsOut ) : int
itemid uint Identifier for the VSITEMID being queried.
sccFile string One of the files associated with the node
stringsOut CALPOLESTR Pointer to an array of CALPOLESTR strings containing the file names for this item.
flagsOut CADWORD /// Pointer to a CADWORD array of flags stored in DWORDs indicating that some of the files have /// special behaviors. ///
리턴 int

GetSelectedNodes() 보호된 메소드

Gets the list of selected HierarchyNode objects
protected GetSelectedNodes ( ) : IList
리턴 IList

GetTargetFramework() 공개 메소드

public GetTargetFramework ( string &ppTargetFramework ) : int
ppTargetFramework string
리턴 int

InitNew() 공개 메소드

public InitNew ( uint formatIndex ) : int
formatIndex uint
리턴 int

InitializeForOuter() 공개 메소드

This is where the initialization occurs.
public InitializeForOuter ( string filename, string location, string name, uint flags, Guid &iid, IntPtr &projectPointer, int &canceled ) : int
filename string
location string
name string
flags uint
iid Guid
projectPointer IntPtr
canceled int
리턴 int

InitializeProjectProperties() 보호된 메소드

Initialize common project properties with default value if they are empty
The following common project properties are defaulted to projectName (if empty): AssemblyName, Name and RootNamespace. If the project filename is not set then no properties are set
protected InitializeProjectProperties ( ) : void
리턴 void

IsCodeFile() 공개 메소드

Determines whether a file is a code file.
public IsCodeFile ( string fileName ) : bool
fileName string Name of the file to be evaluated
리턴 bool

IsCurrentStateASuppressCommandsMode() 보호된 메소드

Defines whther the current mode of the project is in a supress command mode.
protected IsCurrentStateASuppressCommandsMode ( ) : bool
리턴 bool

IsDirty() 공개 메소드

public IsDirty ( int &isDirty ) : int
isDirty int
리턴 int

IsDocumentInProject() 공개 메소드

public IsDocumentInProject ( string mkDoc, int &found, VSDOCUMENTPRIORITY pri, uint &itemId ) : int
mkDoc string
found int
pri VSDOCUMENTPRIORITY
itemId uint
리턴 int

IsEmbeddedResource() 공개 메소드

Determines whether the given file is a resource file (resx file).
public IsEmbeddedResource ( string fileName ) : bool
fileName string Name of the file to be evaluated.
리턴 bool

IsFlavorDirty() 보호된 메소드

protected IsFlavorDirty ( ) : int
리턴 int

IsItemTypeFileType() 보호된 메소드

Called by the project to know if the item is a file (that is part of the project) or an intermediate file used by the MSBuild tasks/targets Override this method if your project has more types or different ones
protected IsItemTypeFileType ( string type ) : bool
type string Type name
리턴 bool

Load() 공개 메소드

public Load ( string fileName, uint mode, int readOnly ) : int
fileName string
mode uint
readOnly int
리턴 int

LoadNonBuildInformation() 보호된 메소드

For flavored projects which implement IPersistXMLFragment, load the information now
protected LoadNonBuildInformation ( ) : void
리턴 void

LoadXmlFragment() 보호된 메소드

Initialize an object with an XML fragment.
protected LoadXmlFragment ( IPersistXMLFragment persistXmlFragment, string configName ) : void
persistXmlFragment IPersistXMLFragment
configName string Name of the configuration being initialized, null if it is the project
리턴 void

NodeFromItemId() 공개 메소드

Get Node from ItemID.
public NodeFromItemId ( uint itemId ) : HierarchyNode
itemId uint ItemID for the requested node
리턴 HierarchyNode

NodeHasDesigner() 공개 메소드

Defines if Node has Designer. By default we do not support designers for nodes
public NodeHasDesigner ( string itemPath ) : bool
itemPath string Path to item to query for designer support
리턴 bool

OnAggregationComplete() 공개 메소드

This is called after the project is done initializing the different layer of the aggregations
public OnAggregationComplete ( ) : int
리턴 int

OnBeforeDropNotify() 공개 메소드

Allows the drag source to prompt to save unsaved items being dropped. Notifies the source hierarchy that information dragged from it is about to be dropped on a target. This method is called immediately after the mouse button is released on a drop.
public OnBeforeDropNotify ( Microsoft.VisualStudio.OLE.Interop.IDataObject o, uint dwEffect, int &fCancelDrop ) : int
o Microsoft.VisualStudio.OLE.Interop.IDataObject /// Reference to the IDataObject interface on the item being dragged. /// This data object contains the data being transferred in the drag-and-drop operation. /// If the drop occurs, then this data object (item) is incorporated into the hierarchy window of the new hierarchy. ///
dwEffect uint Current state of the keyboard and the mouse modifier keys.
fCancelDrop int /// If true, then the drop is cancelled by the source hierarchy. If false, then the drop can /// continue. ///
리턴 int

OnClear() 공개 메소드

Called when your cut/copied operation is canceled
public OnClear ( int wasCut ) : int
wasCut int /// This flag informs the source that the Cut method was called (true), /// rather than Copy (false), so the source knows whether to "un-cut-highlight" the items that were cut. ///
리턴 int

OnDropNotify() 공개 메소드

Notifies clients that the dragged item was dropped.
public OnDropNotify ( int fDropped, uint dwEffects ) : int
fDropped int If true, then the dragged item was dropped on the target. If false, then the drop did not occur.
dwEffects uint /// Visual effects associated with the drag-and-drop operation, such as cursors, bitmaps, and so on. /// The value of dwEffects passed to the source object via OnDropNotify method is the value of pdwEffects returned by /// Drop method. ///
리턴 int

OnOpenItem() 공개 메소드

Called when the project opens an editor window for the given file
public OnOpenItem ( string fullPathToSourceFile ) : void
fullPathToSourceFile string
리턴 void

OnPaste() 공개 메소드

Called after your cut/copied items has been pasted
public OnPaste ( int wasCut, uint dropEffect ) : int
wasCut int /// If true, then the IDataObject has been successfully pasted into a target hierarchy. /// If false, then the cut or copy operation was cancelled. ///
dropEffect uint /// Visual effects associated with the drag and drop operation, such as cursors, bitmaps, and so on. /// These should be the same visual effects used in OnDropNotify ///
리턴 int

OnTargetFrameworkMonikerChanged() 공개 메소드

public OnTargetFrameworkMonikerChanged ( ProjectOptions options, FrameworkName currentTargetFramework, FrameworkName newTargetFramework ) : void
options ProjectOptions
currentTargetFramework FrameworkName
newTargetFramework FrameworkName
리턴 void

OpenDependency() 공개 메소드

public OpenDependency ( string szDependencyCanonicalName, IVsDependency &dependency ) : int
szDependencyCanonicalName string
dependency IVsDependency
리턴 int

OpenItem() 공개 메소드

public OpenItem ( uint itemId, Guid &logicalView, IntPtr punkDocDataExisting, IVsWindowFrame &frame ) : int
itemId uint
logicalView Guid
punkDocDataExisting IntPtr
frame IVsWindowFrame
리턴 int

OpenItemWithSpecific() 공개 메소드

public OpenItemWithSpecific ( uint itemId, uint editorFlags, Guid &editorType, string physicalView, Guid &logicalView, IntPtr docDataExisting, IVsWindowFrame &frame ) : int
itemId uint
editorFlags uint
editorType Guid
physicalView string
logicalView Guid
docDataExisting IntPtr
frame IVsWindowFrame
리턴 int

OverwriteExistingItem() 보호된 메소드

Handle owerwriting of an existing item in the hierarchy.
protected OverwriteExistingItem ( HierarchyNode existingNode ) : void
existingNode HierarchyNode The node that exists.
리턴 void

PasteFromClipboard() 보호된 메소드

Handle the Paste operation to a targetNode
protected PasteFromClipboard ( HierarchyNode targetNode ) : int
targetNode HierarchyNode
리턴 int

PrepareBuild() 공개 메소드

This is called from the main thread before the background build starts. cleanBuild is not part of the vsopts, but passed down as the callpath is differently PrepareBuild mainly creates directories and cleans house if cleanBuild is true
public PrepareBuild ( string config, bool cleanBuild ) : void
config string
cleanBuild bool
리턴 void

ProcessDependentFileNodes() 보호된 메소드

Processes dependent filenodes from list of subitems. Multi level supported, but not circular dependencies.
protected ProcessDependentFileNodes ( IList subitemsKeys, MSBuild.ProjectItem>.Dictionary subitems ) : void
subitemsKeys IList List of sub item keys
subitems MSBuild.ProjectItem>.Dictionary
리턴 void

ProcessFiles() 보호된 메소드

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

ProcessFolders() 보호된 메소드

Loads folders from the project file into the hierarchy.
protected ProcessFolders ( ) : void
리턴 void

ProcessReferences() 보호된 메소드

Loads reference items from the project file into the hierarchy.
protected ProcessReferences ( ) : void
리턴 void

ProjectNode() 보호된 메소드

protected ProjectNode ( ) : System
리턴 System

QueryStatusOnNode() 보호된 메소드

Handles command status on the project node. If a command cannot be handled then the base should be called.
protected QueryStatusOnNode ( Guid cmdGroup, uint cmd, IntPtr pCmdText, QueryStatusResult &result ) : int
cmdGroup Guid /// A unique identifier of the command group. The pguidCmdGroup parameter can be NULL to specify the /// standard group. ///
cmd uint The command to query status for.
pCmdText IntPtr /// Pointer to an OLECMDTEXT structure in which to return the name and/or status information of a /// single command. Can be NULL to indicate that the caller does not require this information. ///
result QueryStatusResult An out parameter specifying the QueryStatusResult of the command.
리턴 int

RegisterClipboardNotifications() 보호된 메소드

Register/Unregister for Clipboard events for the UiHierarchyWindow (solution explorer)
protected RegisterClipboardNotifications ( bool register ) : void
register bool true for register, false for unregister
리턴 void

Reload() 보호된 메소드

Reload project from project file
protected Reload ( ) : void
리턴 void

Remove() 공개 메소드

Removes items from the hierarchy.
public Remove ( bool removeFromStorage ) : void
removeFromStorage bool
리턴 void

RemoveBuildDependency() 공개 메소드

public RemoveBuildDependency ( IVsBuildDependency dependency ) : void
dependency IVsBuildDependency
리턴 void

RemoveItem() 공개 메소드

public RemoveItem ( uint reserved, uint itemId, int &result ) : int
reserved uint
itemId uint
result int
리턴 int

RenameProjectFile() 보호된 메소드

Renames the project file
protected RenameProjectFile ( string newFile ) : void
newFile string The full path of the new project file.
리턴 void

ReopenItem() 공개 메소드

public ReopenItem ( uint itemId, Guid &editorType, string physicalView, Guid &logicalView, IntPtr docDataExisting, IVsWindowFrame &frame ) : int
itemId uint
editorType Guid
physicalView string
logicalView Guid
docDataExisting IntPtr
frame IVsWindowFrame
리턴 int

ResolveAssemblyPathInTargetFx() 공개 메소드

public ResolveAssemblyPathInTargetFx ( string prgAssemblySpecs, uint cAssembliesToResolve, VsResolvedAssemblyPath prgResolvedAssemblyPaths, uint &pcResolvedAssemblyPaths ) : int
prgAssemblySpecs string
cAssembliesToResolve uint
prgResolvedAssemblyPaths VsResolvedAssemblyPath
pcResolvedAssemblyPaths uint
리턴 int

ResumeMSBuild() 공개 메소드

Resumes MSBuild.
public ResumeMSBuild ( string target ) : void
target string
리턴 void

ResumeMSBuild() 공개 메소드

Resumes MSBuild.
public ResumeMSBuild ( string config, IVsOutputWindowPane output, string target ) : void
config string
output IVsOutputWindowPane
target string
리턴 void

ResumeMSBuild() 공개 메소드

Resumes MSBuild.
public ResumeMSBuild ( string config, string target ) : void
config string
target string
리턴 void

Save() 공개 메소드

public Save ( string fileToBeSaved, int remember, uint formatIndex ) : int
fileToBeSaved string
remember int
formatIndex uint
리턴 int

SaveAs() 보호된 메소드

Saves the project file on a new name.
protected SaveAs ( string newFileName ) : int
newFileName string The new name of the project file.
리턴 int

SaveCompleted() 공개 메소드

public SaveCompleted ( string filename ) : int
filename string
리턴 int

SaveMSBuildProjectFileAs() 보호된 메소드

Saves project file related information to the new file name. It also calls msbuild API to save the project file. It is called by the SaveAs method and the SetEditLabel before the project file rename related events are triggered. An implementer can override this method to provide specialized semantics on how the project file is renamed in the msbuild file.
protected SaveMSBuildProjectFileAs ( string newFileName ) : void
newFileName string The new full path of the project file
리턴 void

SccGlyphChanged() 공개 메소드

This method is called by the source control portion of the environment to inform the project of changes to the source control glyph on various nodes.
public SccGlyphChanged ( int affectedNodes, uint itemidAffectedNodes, VsStateIcon newGlyphs, uint newSccStatus ) : int
affectedNodes int Count of changed nodes.
itemidAffectedNodes uint An array of VSITEMID identifiers of the changed nodes.
newGlyphs VsStateIcon /// An array of VsStateIcon glyphs representing the new state of the corresponding item in /// rgitemidAffectedNodes. ///
newSccStatus uint An array of status flags from SccStatus corresponding to rgitemidAffectedNodes.
리턴 int

SetAggregateProjectTypeGuids() 공개 메소드

Set the list of GUIDs that are aggregated together to create this project.
public SetAggregateProjectTypeGuids ( string projectTypeGuids ) : int
projectTypeGuids string /// Semi-colon separated list of GUIDs, the last one is usually the project factory of the /// base project factory ///
리턴 int

SetBuildConfigurationProperties() 보호된 메소드

Set configuration properties for a specific configuration
protected SetBuildConfigurationProperties ( string config ) : void
config string configuration name
리턴 void

SetConfiguration() 보호된 메소드

Set the configuration property in MSBuild. This does not get persisted and is used to evaluate msbuild conditions which are based on the $(Configuration) property.
protected SetConfiguration ( string config ) : void
config string Configuration name
리턴 void

SetCurrentConfiguration() 보호된 메소드

Set the configuration in MSBuild. This does not get persisted and is used to evaluate msbuild conditions which are based on the $(Configuration) property.
protected SetCurrentConfiguration ( ) : void
리턴 void

SetEditLabel() 공개 메소드

Renames the project node.
public SetEditLabel ( string label ) : int
label string The new name
리턴 int

SetGuidProperty() 공개 메소드

Sets Guid properties for the project node.
public SetGuidProperty ( int propid, Guid &guid ) : int
propid int A __VSHPROPID or __VSHPROPID2 value of the guid property
guid Guid The guid value to set.
리턴 int

SetHostObject() 공개 메소드

public SetHostObject ( string targetName, string taskName, object hostObject ) : int
targetName string
taskName string
hostObject object
리턴 int

SetInnerProject() 공개 메소드

We are always the inner most part of the aggregation and as such we don't support setting an inner project
public SetInnerProject ( object innerProject ) : int
innerProject object
리턴 int

SetOutputLogger() 보호된 메소드

Associate window output pane to the build logger
protected SetOutputLogger ( IVsOutputWindowPane output ) : void
output IVsOutputWindowPane
리턴 void

SetProjectFileDirty() 공개 메소드

Set dirty state of project
public SetProjectFileDirty ( bool value ) : void
value bool boolean value indicating dirty state
리턴 void

SetProjectProperty() 공개 메소드

Set value of project property
public SetProjectProperty ( string propertyName, string propertyValue ) : void
propertyName string Name of property
propertyValue string Value of property
리턴 void

SetProperty() 공개 메소드

Sets the properties for the project node.
public SetProperty ( int propid, object value ) : int
propid int /// Identifier of the hierarchy property. For a list of propid values, ///
value object The value to set.
리턴 int

SetSccLocation() 공개 메소드

This method is called by the source control portion of the environment when a project is initially added to source control, or to change some of the project's settings.
public SetSccLocation ( string sccProjectName, string sccAuxPath, string sccLocalPath, string sccProvider ) : int
sccProjectName string /// String, opaque to the project, that identifies the project location on the server. Persist /// this string in the project file. ///
sccAuxPath string /// String, opaque to the project, that identifies the local path to the project. Persist this /// string in the project file. ///
sccLocalPath string /// String, opaque to the project, that identifies the path to the server. Persist this string /// in the project file. ///
sccProvider string /// String, opaque to the project, that identifies the source control package. Persist this /// string in the project file. ///
리턴 int

SetSite() 공개 메소드

Sets the service provider from which to access the services.
public SetSite ( Microsoft.VisualStudio.OLE.Interop.IServiceProvider site ) : int
site Microsoft.VisualStudio.OLE.Interop.IServiceProvider An instance to an Microsoft.VisualStudio.OLE.Interop object
리턴 int

ShowAllFiles() 보호된 메소드

Handles the shows all objects command.
protected ShowAllFiles ( ) : int
리턴 int

StartBatchEdit() 공개 메소드

public StartBatchEdit ( ) : int
리턴 int

SuspendMSBuild() 공개 메소드

Suspends MSBuild
public SuspendMSBuild ( ) : void
리턴 void

TransferItem() 공개 메소드

Implements IVsProject3::TransferItem This function is called when an open miscellaneous file is being transferred to our project. The sequence is for the shell to call AddItemWithSpecific and then use TransferItem to transfer the open document to our project.
public TransferItem ( string oldMkDoc, string newMkDoc, IVsWindowFrame frame ) : int
oldMkDoc string Old document name
newMkDoc string New document name
frame IVsWindowFrame Optional frame if the document is open
리턴 int

UnloadProject() 보호된 메소드

Unloads the project.
protected UnloadProject ( ) : int
리턴 int

UpdateSccStateIcons() 보호된 메소드

Recursevily walks the hierarchy nodes and redraws the state icons
protected UpdateSccStateIcons ( ) : void
리턴 void

UpdateTargetFramework() 공개 메소드

public UpdateTargetFramework ( IVsHierarchy pHier, string currentTargetFramework, string newTargetFramework ) : int
pHier IVsHierarchy
currentTargetFramework string
newTargetFramework string
리턴 int

UpgradeProject() 공개 메소드

public UpgradeProject ( uint grfUpgradeFlags ) : int
grfUpgradeFlags uint
리턴 int

WalkSourceProjectAndAdd() 보호된 메소드

Recursive method that walk a hierarchy and add items it find to our project. Note that this is meant as an helper to the Copy&Paste/Drag&Drop functionality.
protected WalkSourceProjectAndAdd ( IVsHierarchy sourceHierarchy, uint itemId, HierarchyNode targetNode, bool addSiblings ) : void
sourceHierarchy IVsHierarchy Hierarchy to walk
itemId uint Item ID where to start walking the hierarchy
targetNode HierarchyNode Node to start adding to
addSiblings bool
리턴 void