In This Article

ICodeSnippetTemplateSession Interface

Provides the base requirements for an object that represents an IntelliPrompt code snippet template session.

public interface ICodeSnippetTemplateSession : IIntelliPromptSession, IServiceLocator

Properties

ActiveDeclaration

Gets the ICodeSnippetDeclaration that is currently active, if any.

ICodeSnippetDeclaration ActiveDeclaration { get; }

Property Value

ICodeSnippetDeclaration:

The ICodeSnippetDeclaration that is currently active, if any.

CodeSnippet

Gets the code snippet to activate.

ICodeSnippet CodeSnippet { get; }

Property Value

ICodeSnippet:

The code snippet to activate.

IsAutoIndentEnabled

Gets whether to auto-indent code snippet code based on the tabstop level of the current line.

bool IsAutoIndentEnabled { get; }

Property Value

bool:

true if the code snippet code should be auto-indented; otherwise, false.

Methods

Open(IEditorView)

Opens the session, attaching to the specified IEditorView, and uses the current selection as the target snapshot range.

void Open(IEditorView view)
Parameter Type Description
view IEditorView

The IEditorView in which the session is opened.

Inherited Members