API Reference
LiveSessionOptions
Configuration for a single-use live session. Set before starting the session.
Inheritance
- Object
- LiveSessionOptions
Usage
Explore 3 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Accepted by parameters 3
- Method MenuContext.Run
- Constructor LiveSession.LiveSession
- Method LiveSession.Replay
Constructors
public LiveSessionOptions() #Inherited Methods
public virtual Boolean Equals(Object? obj) #BooleanParameters
- obj Object?
Properties
public LiveMode Mode { get; set; } #Full screen (default) or an inline area below the cursor. Without a VT console (CI, redirected output) both fall back to stream lines.
public Int32 FramesPerSecond { get; set; } #Maximum frame frequency, clamped to 1–60; defaults to 15.
public Boolean CaptureConsole { get; set; } #Captures standard output and error while running; defaults to true.
public String? LogTarget { get; set; } #Name of the log target, or null to discover the first log target.
public TerminalProfile? Profile { get; set; } #Profile override, or null for Terminal.Profile.
public CultureInfo? Culture { get; set; } #The culture for numbers and dates in the session's widgets, overriding the profile's (and CONSOLEMONSTER_CULTURE); null keeps the profile culture, which defaults to the current culture.
public ITheme? Theme { get; set; } #Theme override, or null for Terminal.Theme.
public ITerminalOutput? Output { get; set; } #Borrowed output, or null to create and own the terminal output.
public ITerminalTarget? Target { get; set; } #Where the session draws: its profile, theme and writer (see ITerminalTarget), or null for Terminal.Target at start. LiveSessionOptions.Profile, LiveSessionOptions.Theme and LiveSessionOptions.Output still win when set. Only the console target claims the console, probes widths and watches the font.
public Boolean TaskbarProgress { get; set; } #Whether the session drives the terminal's progress indicator (the Windows Terminal tab and taskbar) from its progress bars, lanes, spinners and status, and clears it at the end (default true; see LiveSessionOptions.TaskbarProgress).
public Boolean NotifyOnFinish { get; set; } #Whether the session rings the terminal bell when it ends, to call attention to a finished run (default false).
public String? RecordPath { get; set; } #UTF-8 recording destination, mutually exclusive with RecordWriter.
public TextWriter? RecordWriter { get; set; } #Borrowed recording writer; flushed but left open at shutdown.
public Int32 AutoRecord { get; set; } #Opt-in automatic recording: when above zero and neither LiveSessionOptions.RecordPath nor LiveSessionOptions.RecordWriter is set, the session records itself to LiveSessionOptions.AutoRecordFolder and keeps only this many recordings with its LiveSessionOptions.RecordingName (the newest ones; other files are never removed), so the last runs can be rewound with Show-ConsoleReplay. Default 0 (off).
public Int64 AutoRecordMaxBytes { get; set; } #The most bytes the automatic recordings with one LiveSessionOptions.RecordingName may take together (default 50 MB): older recordings are removed first, and a single recording stops growing at this size.
public String? AutoRecordFolder { get; set; } #Where automatic recordings go, or null for %LOCALAPPDATA%\ConsoleMonster\Recordings (on Linux and macOS the local application data folder, usually ~/.local/share).
public String? RecordingName { get; set; } #The name automatic recordings start with (default session), followed by the start time.
public static String DefaultRecordingFolder { get; } #The default folder for automatic recordings.
public IWidget? Summary { get; set; } #Widget appended to scrollback after live output ends.
public Boolean PrintFinalState { get; set; } #When no LiveSessionOptions.Summary is set, print the final state of the root widget to scrollback after the session ends (default true), so a live dashboard always leaves a record behind.
public TimeSpan StreamHeartbeat { get; set; } #Interval between line-mode summaries; defaults to ten seconds. Zero disables them.
public Boolean? StreamTimestamps { get; set; } #Prefixes each line-mode narration and heartbeat line with the session clock ([mm:ss], or [h:mm:ss] past an hour). Null (the default) enables it when the profile detected a CI environment, where log viewers often lack their own per-line timestamps; true or false forces it. Interactive frames are unaffected.
public Boolean HandleCancelKey { get; set; } #Intercepts the first Ctrl+C for cooperative cancellation; defaults to true.
public Boolean Discoverable { get; set; } #Whether the session can be found through LiveSession.Current (default true), so update cmdlets and prompts started elsewhere reach it. A session that runs other code, such as a test run, turns it off: that code's own updates and prompts then behave as if no dashboard were running.
public TimeSpan StopTimeout { get; set; } #Maximum render-thread join wait; defaults to two seconds. Must be between zero and Int32.MaxValue milliseconds.
public Func<TimeSpan>? Clock { get; set; } #Optional monotonic time source, sampled relative to its value at Start.
public Action<TimeSpan, CancellationToken>? ReplayDelay { get; set; } #Optional replay delay implementation; receives the scaled interval and cancellation token.