IClassificationTypeRegistryService.CreateTransientClassificationType Method (IEnumerable<IClassificationType>)

Creates an IClassificationType that persists only for the duration of this session..

Namespace:  Microsoft.VisualStudio.Text.Classification
Assembly:  Microsoft.VisualStudio.Text.Logic (in Microsoft.VisualStudio.Text.Logic.dll)

Syntax

声明
Function CreateTransientClassificationType ( _
    baseTypes As IEnumerable(Of IClassificationType) _
) As IClassificationType
IClassificationType CreateTransientClassificationType(
    IEnumerable<IClassificationType> baseTypes
)
IClassificationType^ CreateTransientClassificationType(
    IEnumerable<IClassificationType^>^ baseTypes
)
abstract CreateTransientClassificationType : 
        baseTypes:IEnumerable<IClassificationType> -> IClassificationType 
function CreateTransientClassificationType(
    baseTypes : IEnumerable<IClassificationType>
) : IClassificationType

Parameters

Return Value

Type: Microsoft.VisualStudio.Text.Classification.IClassificationType
A new IClassificationType that inherits from all of baseTypes.

Exceptions

Exception Condition
ArgumentNullException

baseTypes is nulla null reference (Nothing in Visual Basic).

InvalidOperationException

baseTypes has zero items.

Remarks

This IClassificationType must inherit from at least one IClassificationType

This method is intended to aid in the runtime display of overlapping classifications.

The classification names generated by this method are determined at run time and are subject to change in future revisions. The only guarantee made is that if two transient IClassificationType objects are created with the same base types, they will have the same classification name.

.NET Framework Security

See Also

Reference

IClassificationTypeRegistryService Interface

CreateTransientClassificationType Overload

Microsoft.VisualStudio.Text.Classification Namespace