Gets information on what defines a comment in the language.
Assemblies: Microsoft.VisualStudio.Package.LanguageService.12.0 (in Microsoft.VisualStudio.Package.LanguageService.12.0.dll)
Microsoft.VisualStudio.Package.LanguageService.10.0 (in Microsoft.VisualStudio.Package.LanguageService.10.0.dll)
Microsoft.VisualStudio.Package.LanguageService.11.0 (in Microsoft.VisualStudio.Package.LanguageService.11.0.dll)
Microsoft.VisualStudio.Package.LanguageService.9.0 (in Microsoft.VisualStudio.Package.LanguageService.9.0.dll)
Microsoft.VisualStudio.Package.LanguageService (in Microsoft.VisualStudio.Package.LanguageService.dll)
To support adding comments to and removing comments from source code, the Source class needs to know what defines a line comment (runs from the line comment characters to the end of the line) and block comment (runs from the start block comment characters to the end block comment characters, often spanning multiple lines). This method provides that information. If your language does not use the C#/C++ format for comments, then you must derive a class from the Source class and override this method to provide the appropriate comment delimiters.
The base method creates a new CommentInfo and fills it in with C#/C++ line and block comment delimiters, specifically, "//", "/*", and "*/". The base method also indicates that line comments can be used.
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.