C# 클래스 hoTools.Query.SqlTabPagesCntrl

SqlTabPagesCntrl creates and handles TabPages of a ControlTab to work with *.sql files. - Create Menu Items -- Templates SQL -- Templates Macros - Events - SQL File properties
파일 보기 프로젝트 열기: Helmut-Ortmann/EnterpriseArchitect_hoTools 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
MenuLoadTabFileText string
MenuLoadTabFileTooltip string
MenuLoadTabFromRecentFileText string
MenuLoadTabFromRecentFileTooltip string
MenuNewTabFromRecentText string
MenuNewTabFromRecentTooltip string
MenuNewTabText string
MenuNewTabTooltip string
MenuNewTabWithFileDialogText string
MenuNewTabWithFileDialogTooltip string
MenuReLoadTabText string
MenuReLoadTabTooltip string

공개 메소드들

메소드 설명
AddTab ( ) : TabPage

Add an Tab to the tab control and load the Element Template as default. The Text box is unchanged because it's just a template.

AddTab ( string content ) : TabPage

Add a tab to the tab control and load content into the tab.If the content is empty nothing is loaded.

AddTabWithFileDialog ( ) : TabPage

Add Tab with file dialog to load file

Close ( TabPage tabPage ) : void

Close TabPage - Ask to store content if changed

CloseAll ( ) : void

Close all Tab Pages

LoadTabPagePerFileDialog ( ) : void

Load sql string from *.sql File into active TabPage with TextBox inside. - Update and save the list of sql files

RedoText ( ) : void

Redo changes in current active TextBoxUndo

ReloadTabPage ( ) : void

Reload current Tab

ReloadTabPageWithAsk ( ) : void

Reload current tab and ask if the user wants it. It checks the file for differences before asking.

RunSqlTabPage ( ) : void

Run SQL for selected TabPage

Save ( bool configSave = true ) : void

Save current active TabPage

SaveAll ( ) : void

Save all unchanged Tabs.

SaveAs ( ) : void

Save sql Tab As...

SaveSqlTabAs ( ) : void

Save current Tab into desired file

SqlTabPagesCntrl ( Model model, AddinSettings settings, System components, TabControl tabControl, TextBox sqlTextBoxSearchTerm, ToolStripMenuItem fileNewTabAndLoadRecentFileMenuItem, ToolStripMenuItem fileLoadTabRecentFileMenuItem, string addinTabName ) : System

Constructor to Initialize TabControl, create ToolStripItems (New Tab from, Recent Files) with file history.

UndoText ( ) : void

Undo changes in current active TextBoxUndo

비공개 메소드들

메소드 설명
BranchConstantPackageTemplateText ( SqlTemplate template, string templateText ) : string

Insert Branch for a constant package like: '#Branch={.....guid...}'. If the context Element is a package it inserts the Package Id.

GetMacroMenuItems ( ) : ToolStripMenuItem

Get Macro Menu Items. Every item contains: - Macro name - Tooltip - Tag Template - Event Handler insertTemplate_Click

GetTemplateMenuItems ( ) : ToolStripMenuItem

Get Template Menu Items. Every item contains: - Template name - Tooltip - Tag Template - Event Handler insertTemplate_Click

GuidConstant ( SqlTemplate template, string templateText ) : string

Returns guid of it selected and has a supported type (Package, Diagram, Element, Attribute, Operation)

IdConstant ( SqlTemplate template, string templateText ) : string

Returns string of id of it selected and has a supported type (Package, Diagram, Element, Attribute, Operation).It also copies the id to Clipboard.

InsertRecentFileLists ( string fileName ) : void

Insert recent file lists - SqlFile -OpenedTabs

LoadOpenedTabsFromLastSession ( ) : void

Load all tabs which were opened in the last session

LoadRecentFilesIntoToolStripItems ( ) : void

Update the following Menu Items with recent files: -File, Load Tab from.. -File, Add Tab from.. -Tab, Load Tab from.. -Tab, Add Tab from..

LoadRecentFilesMenuItems ( ToolStripMenuItem loadRecentFileStripMenuItem, EventHandler eventHandlerClick ) : void

Load RecentFiles MenuItems into MenuItemStrip

LoadTabPage ( string tabContent ) : void

Load string for tab Page

LoadTabPageFromFile ( TabPage tabPage, string fileName, bool notUpdateLastOpenedList = false ) : void

Load file for tab Page

Save ( TabPage tabPage, bool configSave = true ) : void

Save sql TabPage in *.sql File. Store the save time to distinguish hoTools writes from other

SaveAs ( TabPage tabPage ) : void

Save As... TabPage in *.sql File.

ToolstripMenuItemInsertTemplateFromId ( SqlTemplates id, string caption ) : ToolStripMenuItem

New ToolStripItem to insert a template. The EventHandler is: insertTemplate_Click. It sets: Caption text, Tooltip, EventHandler, Tag with the template itself

addTabFileDialogMenuItem_Click ( object sender, EventArgs e ) : void

Add Tab with File Dialog

addTabMenuItem_Click ( object sender, EventArgs e ) : void

Add tab fired by TabControl or TabPage

closeMenuItem_Click ( object sender, EventArgs e ) : void

Event Close TabPage

fileLoadMenuItem_Click ( object sender, EventArgs e ) : void

Event File Load fired by TabControl

fileRunMenuItem_Click ( object sender, EventArgs e ) : void
fileRunSelectedMenuItem_Click ( object sender, EventArgs e ) : void

Run sql for selected Text

fileSaveAllMenuItem_Click ( object sender, EventArgs e ) : void

Event File Save

fileSaveAsMenuItem_Click ( object sender, EventArgs e ) : void

Event File Save As

fileSaveMenuItem_Click ( object sender, EventArgs e ) : void

Event File Save

insertTemplate_Click ( object sender, EventArgs e ) : void

Inserts the selected macro at the cursor position or replace the selected text by the macro. The template is identified by the .Tag property of the menuItem passed by the sender parameter.

loadFromHistoryEntry_Click ( object sender, EventArgs e ) : void

Load from history item in active tab. If no active tab exists create one.

newTabAndLoadFromHistoryEntry_Click ( object sender, EventArgs e ) : void

New Tab and Load from history item

reLoadTabMenuItem_Click ( object sender, EventArgs e ) : void
sqlTextBox_KeyUp ( object sender, KeyEventArgs e ) : void

Handle CTRL sequences for CTRL+S (Store sql) and CTRL+R (RUN sql)

메소드 상세

AddTab() 공개 메소드

Add an Tab to the tab control and load the Element Template as default. The Text box is unchanged because it's just a template.
public AddTab ( ) : TabPage
리턴 System.Windows.Forms.TabPage

AddTab() 공개 메소드

Add a tab to the tab control and load content into the tab.If the content is empty nothing is loaded.
public AddTab ( string content ) : TabPage
content string Content of the Tab
리턴 System.Windows.Forms.TabPage

AddTabWithFileDialog() 공개 메소드

Add Tab with file dialog to load file
public AddTabWithFileDialog ( ) : TabPage
리턴 System.Windows.Forms.TabPage

Close() 공개 메소드

Close TabPage - Ask to store content if changed
public Close ( TabPage tabPage ) : void
tabPage System.Windows.Forms.TabPage
리턴 void

CloseAll() 공개 메소드

Close all Tab Pages
public CloseAll ( ) : void
리턴 void

LoadTabPagePerFileDialog() 공개 메소드

Load sql string from *.sql File into active TabPage with TextBox inside. - Update and save the list of sql files
public LoadTabPagePerFileDialog ( ) : void
리턴 void

RedoText() 공개 메소드

Redo changes in current active TextBoxUndo
public RedoText ( ) : void
리턴 void

ReloadTabPage() 공개 메소드

Reload current Tab
public ReloadTabPage ( ) : void
리턴 void

ReloadTabPageWithAsk() 공개 메소드

Reload current tab and ask if the user wants it. It checks the file for differences before asking.
public ReloadTabPageWithAsk ( ) : void
리턴 void

RunSqlTabPage() 공개 메소드

Run SQL for selected TabPage
public RunSqlTabPage ( ) : void
리턴 void

Save() 공개 메소드

Save current active TabPage
public Save ( bool configSave = true ) : void
configSave bool Default: true, whether to store the configuration
리턴 void

SaveAll() 공개 메소드

Save all unchanged Tabs.
public SaveAll ( ) : void
리턴 void

SaveAs() 공개 메소드

Save sql Tab As...
public SaveAs ( ) : void
리턴 void

SaveSqlTabAs() 공개 메소드

Save current Tab into desired file
public SaveSqlTabAs ( ) : void
리턴 void

SqlTabPagesCntrl() 공개 메소드

Constructor to Initialize TabControl, create ToolStripItems (New Tab from, Recent Files) with file history.
public SqlTabPagesCntrl ( Model model, AddinSettings settings, System components, TabControl tabControl, TextBox sqlTextBoxSearchTerm, ToolStripMenuItem fileNewTabAndLoadRecentFileMenuItem, ToolStripMenuItem fileLoadTabRecentFileMenuItem, string addinTabName ) : System
model EAAddinFramework.Utils.Model
settings hoTools.Settings.AddinSettings
components System
tabControl System.Windows.Forms.TabControl
sqlTextBoxSearchTerm System.Windows.Forms.TextBox
fileNewTabAndLoadRecentFileMenuItem System.Windows.Forms.ToolStripMenuItem File, New Tab from recent files
fileLoadTabRecentFileMenuItem System.Windows.Forms.ToolStripMenuItem File, Load Tab from recent files
addinTabName string
리턴 System

UndoText() 공개 메소드

Undo changes in current active TextBoxUndo
public UndoText ( ) : void
리턴 void

프로퍼티 상세

MenuLoadTabFileText 공개적으로 정적으로 프로퍼티

public static string MenuLoadTabFileText
리턴 string

MenuLoadTabFileTooltip 공개적으로 정적으로 프로퍼티

public static string MenuLoadTabFileTooltip
리턴 string

MenuLoadTabFromRecentFileText 공개적으로 정적으로 프로퍼티

public static string MenuLoadTabFromRecentFileText
리턴 string

MenuLoadTabFromRecentFileTooltip 공개적으로 정적으로 프로퍼티

public static string MenuLoadTabFromRecentFileTooltip
리턴 string

MenuNewTabFromRecentText 공개적으로 정적으로 프로퍼티

public static string MenuNewTabFromRecentText
리턴 string

MenuNewTabFromRecentTooltip 공개적으로 정적으로 프로퍼티

public static string MenuNewTabFromRecentTooltip
리턴 string

MenuNewTabText 공개적으로 정적으로 프로퍼티

public static string MenuNewTabText
리턴 string

MenuNewTabTooltip 공개적으로 정적으로 프로퍼티

public static string MenuNewTabTooltip
리턴 string

MenuNewTabWithFileDialogText 공개적으로 정적으로 프로퍼티

public static string MenuNewTabWithFileDialogText
리턴 string

MenuNewTabWithFileDialogTooltip 공개적으로 정적으로 프로퍼티

public static string MenuNewTabWithFileDialogTooltip
리턴 string

MenuReLoadTabText 공개적으로 정적으로 프로퍼티

public static string MenuReLoadTabText
리턴 string

MenuReLoadTabTooltip 공개적으로 정적으로 프로퍼티

public static string MenuReLoadTabTooltip
리턴 string