Partager via


IEditorCommandHandlerServiceFactory.GetService Method

Definition

Overloads

GetService(ITextView)

Gets or creates an IEditorCommandHandlerService instance for a given ITextView.

GetService(ITextView, ITextBuffer)

Creates a new IEditorCommandHandlerService instance for a given ITextView and ITextBuffer.

GetService(ITextView)

Gets or creates an IEditorCommandHandlerService instance for a given ITextView.

public:
 Microsoft::VisualStudio::Text::Editor::Commanding::IEditorCommandHandlerService ^ GetService(Microsoft::VisualStudio::Text::Editor::ITextView ^ textView);
public Microsoft.VisualStudio.Text.Editor.Commanding.IEditorCommandHandlerService GetService (Microsoft.VisualStudio.Text.Editor.ITextView textView);
abstract member GetService : Microsoft.VisualStudio.Text.Editor.ITextView -> Microsoft.VisualStudio.Text.Editor.Commanding.IEditorCommandHandlerService
Public Function GetService (textView As ITextView) As IEditorCommandHandlerService

Parameters

textView
ITextView

A text view to get or create IEditorCommandHandlerService for.

Returns

Remarks

Only one IEditorCommandHandlerService instance is ever created for each ITextView.

Applies to

GetService(ITextView, ITextBuffer)

Creates a new IEditorCommandHandlerService instance for a given ITextView and ITextBuffer.

public:
 Microsoft::VisualStudio::Text::Editor::Commanding::IEditorCommandHandlerService ^ GetService(Microsoft::VisualStudio::Text::Editor::ITextView ^ textView, Microsoft::VisualStudio::Text::ITextBuffer ^ subjectBuffer);
public Microsoft.VisualStudio.Text.Editor.Commanding.IEditorCommandHandlerService GetService (Microsoft.VisualStudio.Text.Editor.ITextView textView, Microsoft.VisualStudio.Text.ITextBuffer subjectBuffer);
abstract member GetService : Microsoft.VisualStudio.Text.Editor.ITextView * Microsoft.VisualStudio.Text.ITextBuffer -> Microsoft.VisualStudio.Text.Editor.Commanding.IEditorCommandHandlerService
Public Function GetService (textView As ITextView, subjectBuffer As ITextBuffer) As IEditorCommandHandlerService

Parameters

textView
ITextView

A text view to create IEditorCommandHandlerService for.

subjectBuffer
ITextBuffer

A text buffer to create IEditorCommandHandlerService for.

Returns

Applies to