C# Class VsTeXProject.VisualStudio.Project.SingleFileGenerator

Provides support for single file generator.
Inheritance: ISingleFileGenerator, IVsGeneratorProgress
Afficher le fichier Open project: mimura1133/vstex

Méthodes publiques

Méthode Description
GeneratorError ( int warning, uint level, string err, uint line, uint col ) : int
Progress ( uint complete, uint total ) : int
RunGenerator ( string document ) : void

Runs the generator on the current project item.

Méthodes protégées

Méthode Description
ComputeNamespace ( string projectItemPath ) : string

Computes the names space based on the folder for the ProjectItem. It just replaces DirectorySeparatorCharacter with "." for the directory in which the file is located.

InvokeGenerator ( FileNode fileNode ) : void

Invokes the specified generator

UpdateGeneratedCodeFile ( FileNode fileNode, byte data, int size, string fileName ) : string

This is called after the single file generator has been invoked to create or update the code file.

Private Methods

Méthode Description
CanEditFile ( string documentMoniker ) : bool

This function asks to the QueryEditQuerySave service if it is possible to edit the file.

GetBufferContents ( string fileName, IVsTextStream &srpStream ) : string

Returns the buffer contents for a moniker.

SingleFileGenerator ( ProjectNode projectMgr ) : System

Overloadde ctor.

VerifyFileDirtyInRdt ( string document, IVsHierarchy &pHier, IVsPersistDocData &ppDocData, uint &cookie ) : bool

Returns TRUE if open and dirty. Note that documents can be open without a window frame so be careful. Returns the DocData and doc cookie if requested

Method Details

ComputeNamespace() protected méthode

Computes the names space based on the folder for the ProjectItem. It just replaces DirectorySeparatorCharacter with "." for the directory in which the file is located.
protected ComputeNamespace ( string projectItemPath ) : string
projectItemPath string
Résultat string

GeneratorError() public méthode

public GeneratorError ( int warning, uint level, string err, uint line, uint col ) : int
warning int
level uint
err string
line uint
col uint
Résultat int

InvokeGenerator() protected méthode

Invokes the specified generator
protected InvokeGenerator ( FileNode fileNode ) : void
fileNode FileNode The node on which to invoke the generator.
Résultat void

Progress() public méthode

public Progress ( uint complete, uint total ) : int
complete uint
total uint
Résultat int

RunGenerator() public méthode

Runs the generator on the current project item.
public RunGenerator ( string document ) : void
document string
Résultat void

UpdateGeneratedCodeFile() protected méthode

This is called after the single file generator has been invoked to create or update the code file.
protected UpdateGeneratedCodeFile ( FileNode fileNode, byte data, int size, string fileName ) : string
fileNode FileNode The node associated to the generator
data byte data to update the file with
size int size of the data
fileName string Name of the file to update or create
Résultat string