Class MonacoEditorControl
SQL editor control that hosts the Monaco editor in a WebView2 and optionally
provides AI-driven SQL autocompletion through the Reportman agent, including
schema selection and inline/list completion suggestions.
Inheritance
MonacoEditorControl
Assembly: Reportman.Designer.dll
Syntax
public class MonacoEditorControl : UserControl, IDropTarget, ISynchronizeInvoke, IWin32Window, IBindableComponent, IComponent, IDisposable, IContainerControl
Constructors
View Source
MonacoEditorControl()
Declaration
public MonacoEditorControl()
Properties
View Source
ApiKey
Declaration
[Browsable(false)]
public string ApiKey { get; set; }
Property Value
View Source
EnableSqlAutocompleteUi
Declaration
[Browsable(false)]
public bool EnableSqlAutocompleteUi { get; set; }
Property Value
View Source
HubDatabaseId
Declaration
[Browsable(false)]
public long HubDatabaseId { get; }
Property Value
View Source
HubSchemaId
Declaration
[Browsable(false)]
public long HubSchemaId { get; }
Property Value
View Source
RuntimeDb
Declaration
[Browsable(false)]
public string RuntimeDb { get; set; }
Property Value
View Source
SQL
Declaration
[Browsable(false)]
public string SQL { get; set; }
Property Value
Methods
View Source
Dispose(bool)
Declaration
protected override void Dispose(bool disposing)
Parameters
| Type |
Name |
Description |
| bool |
disposing |
|
Overrides
View Source
GetSqlFromEditorAsync()
Declaration
public Task<string> GetSqlFromEditorAsync()
Returns
View Source
OnLoad(EventArgs)
Declaration
protected override void OnLoad(EventArgs e)
Parameters
Overrides
View Source
SendAICompletionsAsync(string, string)
Declaration
public Task SendAICompletionsAsync(string requestId, string responseJson)
Parameters
Returns
View Source
SetBaseConnectionContext(long, long, string, string)
Declaration
public void SetBaseConnectionContext(long hubDatabaseId, long hubSchemaId, string apiKey = "", string runtimeDb = "")
Parameters
View Source
SetHubContext(long, long)
Declaration
public void SetHubContext(long hubDatabaseId, long hubSchemaId)
Parameters
| Type |
Name |
Description |
| long |
hubDatabaseId |
|
| long |
hubSchemaId |
|
View Source
SetHubContext(long, long, string)
Declaration
public void SetHubContext(long hubDatabaseId, long hubSchemaId, string apiKey)
Parameters
| Type |
Name |
Description |
| long |
hubDatabaseId |
|
| long |
hubSchemaId |
|
| string |
apiKey |
|
Events
View Source
SchemaContextChanged
Declaration
public event EventHandler<SqlSchemaContextChangedEventArgs> SchemaContextChanged
Event Type
View Source
SqlContentChanged
Declaration
public event EventHandler SqlContentChanged
Event Type
Implements