Share via


BaseCodeGenerator Class

A managed wrapper for VS's concept of an IVsSingleFileGenerator which is a custom tool invoked during the build which can take any file as an input and provide a compilable code file as output.

Inheritance Hierarchy

System.Object
  Microsoft.VisualStudio.TextTemplating.VSHost.BaseCodeGenerator
    Microsoft.VisualStudio.TextTemplating.VSHost.BaseCodeGeneratorWithSite

Namespace:  Microsoft.VisualStudio.TextTemplating.VSHost
Assembly:  Microsoft.VisualStudio.TextTemplating.VSHost.12.0 (in Microsoft.VisualStudio.TextTemplating.VSHost.12.0.dll)

Syntax

'Declaration
Public MustInherit Class BaseCodeGenerator _
    Implements IVsSingleFileGenerator, IDisposable
public abstract class BaseCodeGenerator : IVsSingleFileGenerator, 
    IDisposable
public ref class BaseCodeGenerator abstract : IVsSingleFileGenerator, 
    IDisposable
[<AbstractClass>]
type BaseCodeGenerator =  
    class 
        interface IVsSingleFileGenerator 
        interface IDisposable 
    end
public abstract class BaseCodeGenerator implements IVsSingleFileGenerator, IDisposable

The BaseCodeGenerator type exposes the following members.

Constructors

  Name Description
Protected method BaseCodeGenerator

Top

Properties

  Name Description
Protected property FileNamespace namespace for the file.
Protected property InputFilePath file-path for the input file.

Top

Methods

  Name Description
Public method Dispose() Releases all resources used by this instance.
Protected method Dispose(Boolean)
Public method Equals Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize (Overrides Object.Finalize().)
Public method Generate
Protected method GenerateCode
Protected method GeneratorErrorCallback
Public method GetDefaultExtension gets the default extension for this generator
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method ToString Returns a string that represents the current object. (Inherited from Object.)

Top

Explicit Interface Implementations

  Name Description
Explicit interface implemetationPrivate method IVsSingleFileGenerator.DefaultExtension
Explicit interface implemetationPrivate method IVsSingleFileGenerator.Generate

Top

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

Microsoft.VisualStudio.TextTemplating.VSHost Namespace