Skip to the content.

PromptPlus API:IConsoleExtendDrive

Build Publish License NuGet Downloads

Back to List Api

IConsoleExtendDrive

Namespace: PPlus

Represents the interface for extend console.

public interface IConsoleExtendDrive

Properties

CurrentBuffer

Get Current Screen Buffer

public abstract TargetBuffer CurrentBuffer { get; }

Property Value

TargetBuffer

EnabledExtend

The extend capacity is enabled

public abstract bool EnabledExtend { get; }

Property Value

Boolean

Methods

OnBuffer(TargetBuffer, Action<CancellationToken>, Nullable<ConsoleColor>, Nullable<ConsoleColor>, Nullable<CancellationToken>)

Run a action on target screen buffer and return to original screen buffer

bool OnBuffer(TargetBuffer target, Action<CancellationToken> value, Nullable<ConsoleColor> defaultforecolor, Nullable<ConsoleColor> defaultbackcolor, Nullable<CancellationToken> cancellationToken)

Parameters

target TargetBuffer
The target buffer

value Action<CancellationToken>
The action

defaultforecolor Nullable<ConsoleColor>
The default fore color

defaultbackcolor Nullable<ConsoleColor>
The default back color

cancellationToken Nullable<CancellationToken>
The CancellationToken

Returns

True when console has capacity to run on target buffer, otherwhise false

SwapBuffer(TargetBuffer)

Swap Screen Buffer

bool SwapBuffer(TargetBuffer value)

Parameters

value TargetBuffer
The target buffer

Returns

True when console has capacity to swap to target buffer, otherwhise false


Back to List Api