Index: Doc/Extra/Provider/dbfactorysupport.html
==================================================================
--- Doc/Extra/Provider/dbfactorysupport.html
+++ Doc/Extra/Provider/dbfactorysupport.html
@@ -59,11 +59,11 @@
<configuration>
<system.data>
<DbProviderFactories>
<remove invariant="System.Data.SQLite"/>
<add name="SQLite Data Provider" invariant="System.Data.SQLite"
- description=".Net Framework Data Provider for SQLite"
type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite" />
+ description=".NET Framework Data Provider for SQLite"
type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite" />
</DbProviderFactories>
</system.data>
</configuration>
@@ -81,11 +81,11 @@
<configuration>
<system.data>
<DbProviderFactories>
<remove invariant="System.Data.SQLite"/>
<add name="SQLite Data Provider" invariant="System.Data.SQLite"
- description=".Net Framework Data Provider for SQLite"
+ description=".NET Framework Data Provider for SQLite"
type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite,
Version=1.0.94.0, Culture=neutral,
PublicKeyToken=db937bc2d44ff139"/>
</DbProviderFactories>
</system.data>
Index: Doc/Extra/Provider/version.html
==================================================================
--- Doc/Extra/Provider/version.html
+++ Doc/Extra/Provider/version.html
@@ -1080,11 +1080,11 @@
Added SQLiteMetaDataCollectionNames class.
1.0.24.6 beta - January 23, 2006
- This beta is built from sqlite.org's 3.3.2 beta.
- Eliminated the static linking of mscoree from all binaries. Native projects
- can now use the library without any dependencies on the .NET framework, while managed
+ can now use the library without any dependencies on the .NET Framework, while managed
projects continue to be able to use the library normally.
1.0.24.5 beta - January 20, 2006
- This beta is built from sqlite.org's 3.3.1 alpha and contains development-in-progress code. Therefore no guarantees
can be made regarding its suitability for production use.
Index: SQLite.Designer/Editors/ViewDesignerDoc.cs
==================================================================
--- SQLite.Designer/Editors/ViewDesignerDoc.cs
+++ SQLite.Designer/Editors/ViewDesignerDoc.cs
@@ -75,11 +75,11 @@
_typeQB = SQLiteDataAdapterToolboxItem._vsdesigner.GetType("Microsoft.VSDesigner.Data.Design.QueryBuilderControl");
if (_typeQB != null)
{
_queryDesigner = Activator.CreateInstance(_typeQB) as UserControl;
- _typeQB.InvokeMember("Provider", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.SetProperty | System.Reflection.BindingFlags.NonPublic, null, _queryDesigner, new object[] { "System.Data.SQLite" });
+ _typeQB.InvokeMember("Provider", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.SetProperty | System.Reflection.BindingFlags.NonPublic, null, _queryDesigner, new object[] { SQLiteOptions.GetProviderName() });
_typeQB.InvokeMember("ConnectionString", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.SetProperty | System.Reflection.BindingFlags.NonPublic, null, _queryDesigner, new object[] { _connection.ConnectionSupport.ConnectionString });
_typeQB.InvokeMember("EnableMorphing", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.SetProperty | System.Reflection.BindingFlags.NonPublic, null, _queryDesigner, new object[] { false });
Controls.Add(_queryDesigner);
_queryDesigner.Dock = DockStyle.Fill;
_queryDesigner.Visible = true;
Index: SQLite.Designer/SQLite.Designer.2005.csproj
==================================================================
--- SQLite.Designer/SQLite.Designer.2005.csproj
+++ SQLite.Designer/SQLite.Designer.2005.csproj
@@ -133,10 +133,11 @@
+
Form
Index: SQLite.Designer/SQLite.Designer.2008.csproj
==================================================================
--- SQLite.Designer/SQLite.Designer.2008.csproj
+++ SQLite.Designer/SQLite.Designer.2008.csproj
@@ -138,10 +138,11 @@
+
Form
Index: SQLite.Designer/SQLite.Designer.2010.csproj
==================================================================
--- SQLite.Designer/SQLite.Designer.2010.csproj
+++ SQLite.Designer/SQLite.Designer.2010.csproj
@@ -138,10 +138,11 @@
+
Form
Index: SQLite.Designer/SQLite.Designer.2012.csproj
==================================================================
--- SQLite.Designer/SQLite.Designer.2012.csproj
+++ SQLite.Designer/SQLite.Designer.2012.csproj
@@ -144,10 +144,11 @@
+
Form
Index: SQLite.Designer/SQLite.Designer.2013.csproj
==================================================================
--- SQLite.Designer/SQLite.Designer.2013.csproj
+++ SQLite.Designer/SQLite.Designer.2013.csproj
@@ -144,10 +144,11 @@
+
Form
Index: SQLite.Designer/SQLiteConnectionProperties.cs
==================================================================
--- SQLite.Designer/SQLiteConnectionProperties.cs
+++ SQLite.Designer/SQLiteConnectionProperties.cs
@@ -21,11 +21,11 @@
: this(null)
{
}
public SQLiteConnectionProperties(string connectionString)
- : base("System.Data.SQLite", connectionString)
+ : base(SQLiteOptions.GetProviderName(), connectionString)
{
}
public override string[] GetBasicProperties()
{
@@ -40,11 +40,11 @@
}
public override bool Contains(string propertyName)
{
if (String.Compare(propertyName, "Database", StringComparison.OrdinalIgnoreCase) == 0)
- return (base.Contains("data source") || base.Contains("uri"));
+ return (base.Contains("data source") || base.Contains("uri") || base.Contains("fulluri"));
return base.Contains(propertyName);
}
public override object this[string propertyName]
@@ -66,10 +66,12 @@
{
if (this["data source"] is string && ((string)this["data source"]).Length > 0)
return (string)this["data source"];
else if (this["uri"] is string)
return MapUriPath((string)this["uri"]);
+ else if (this["fulluri"] is string)
+ return (string)this["fulluri"];
return String.Empty;
}
public override bool IsComplete
{
@@ -82,10 +84,15 @@
}
else if (Contains("uri") == true)
{
if (this["uri"] is string && MapUriPath((string)this["uri"]).Length > 0)
return true;
+ }
+ else if (Contains("fulluri") == true)
+ {
+ if (this["fulluri"] is string && ((string)this["fulluri"]).Length > 0)
+ return true;
}
return false;
}
}
Index: SQLite.Designer/SQLiteConnectionStringEditor.cs
==================================================================
--- SQLite.Designer/SQLiteConnectionStringEditor.cs
+++ SQLite.Designer/SQLiteConnectionStringEditor.cs
@@ -58,11 +58,11 @@
if (_managerType != null)
{
object manager = Activator.CreateInstance(_managerType, new object[] { provider });
if (manager != null)
{
- index = (int)_managerType.InvokeMember("AddNewConnection", BindingFlags.Instance | BindingFlags.InvokeMethod | BindingFlags.Public, null, manager, new object[] { "System.Data.SQLite" });
+ index = (int)_managerType.InvokeMember("AddNewConnection", BindingFlags.Instance | BindingFlags.InvokeMethod | BindingFlags.Public, null, manager, new object[] { SQLiteOptions.GetProviderName() });
if (index > -1 && _selector != null)
{
connectionString = (string)_managerType.InvokeMember("GetConnectionString", BindingFlags.Instance | BindingFlags.InvokeMethod | BindingFlags.Public, null, manager, new object[] { index });
_selector.SelectedNode = _selector.AddNode((string)_managerType.InvokeMember("GetConnectionName", BindingFlags.Instance | BindingFlags.InvokeMethod | BindingFlags.Public, null, manager, new object[] { index }), connectionString, null);
}
@@ -102,11 +102,11 @@
for (int n = 0; n < items; n++)
{
connectionString = (string)_managerType.InvokeMember("GetConnectionString", BindingFlags.Instance | BindingFlags.InvokeMethod | BindingFlags.Public, null, manager, new object[] { n });
connectionName = (string)_managerType.InvokeMember("GetConnectionName", BindingFlags.Instance | BindingFlags.InvokeMethod | BindingFlags.Public, null, manager, new object[] { n });
dataProvider = (string)_managerType.InvokeMember("GetProvider", BindingFlags.Instance | BindingFlags.InvokeMethod | BindingFlags.Public, null, manager, new object[] { n });
- if (String.Compare(dataProvider, "System.Data.SQLite", StringComparison.OrdinalIgnoreCase) == 0)
+ if (String.Compare(dataProvider, SQLiteOptions.GetProviderName(), StringComparison.OrdinalIgnoreCase) == 0)
{
node = selector.AddNode(connectionName, connectionString, null);
if (String.Compare(connectionString, connection.ConnectionString, StringComparison.OrdinalIgnoreCase) == 0)
selector.SelectedNode = node;
Index: SQLite.Designer/SQLiteConnectionUIControl.Designer.cs
==================================================================
--- SQLite.Designer/SQLiteConnectionUIControl.Designer.cs
+++ SQLite.Designer/SQLiteConnectionUIControl.Designer.cs
@@ -1,358 +1,382 @@
/********************************************************
* ADO.NET 2.0 Data Provider for SQLite Version 3.X
* Written by Robert Simpson (robert@blackcastlesoft.com)
- *
+ *
* Released to the public domain, use at your own risk!
- ********************************************************/
-
-namespace SQLite.Designer
-{
- partial class SQLiteConnectionUIControl
- {
- ///
- /// Required designer variable.
- ///
- private System.ComponentModel.IContainer components = null;
-
- ///
- /// Clean up any resources being used.
- ///
- /// true if managed resources should be disposed; otherwise, false.
- protected override void Dispose(bool disposing)
- {
- if (disposing && (components != null))
- {
- components.Dispose();
- }
- base.Dispose(disposing);
- }
-
- #region Windows Form Designer generated code
-
- ///
- /// Required method for Designer support - do not modify
- /// the contents of this method with the code editor.
- ///
- private void InitializeComponent()
- {
- System.Windows.Forms.Label labelPassword;
- System.Windows.Forms.GroupBox securityGroup;
- System.Windows.Forms.GroupBox encodingGroup;
- System.Windows.Forms.GroupBox dateTimeGroup;
- System.Windows.Forms.GroupBox databaseGroup;
- System.Windows.Forms.Label cacheSizeLabel;
- System.Windows.Forms.Label pageSizeLabel;
- System.Windows.Forms.GroupBox syncGroup;
- this.passwordTextBox = new System.Windows.Forms.TextBox();
- this.utf16RadioButton = new System.Windows.Forms.RadioButton();
- this.utf8RadioButton = new System.Windows.Forms.RadioButton();
- this.ticksRadioButton = new System.Windows.Forms.RadioButton();
- this.iso8601RadioButton = new System.Windows.Forms.RadioButton();
- this.cacheSizeTextbox = new System.Windows.Forms.TextBox();
- this.pageSizeTextBox = new System.Windows.Forms.TextBox();
- this.fileTextBox = new System.Windows.Forms.TextBox();
- this.browseButton = new System.Windows.Forms.Button();
- this.newDatabase = new System.Windows.Forms.Button();
- this.offRadioButton = new System.Windows.Forms.RadioButton();
- this.normalRadioButton = new System.Windows.Forms.RadioButton();
- this.fullRadioButton = new System.Windows.Forms.RadioButton();
- this.julianRadioButton = new System.Windows.Forms.RadioButton();
- labelPassword = new System.Windows.Forms.Label();
- securityGroup = new System.Windows.Forms.GroupBox();
- encodingGroup = new System.Windows.Forms.GroupBox();
- dateTimeGroup = new System.Windows.Forms.GroupBox();
- databaseGroup = new System.Windows.Forms.GroupBox();
- cacheSizeLabel = new System.Windows.Forms.Label();
- pageSizeLabel = new System.Windows.Forms.Label();
- syncGroup = new System.Windows.Forms.GroupBox();
- securityGroup.SuspendLayout();
- encodingGroup.SuspendLayout();
- dateTimeGroup.SuspendLayout();
- databaseGroup.SuspendLayout();
- syncGroup.SuspendLayout();
- this.SuspendLayout();
- //
- // labelPassword
- //
- labelPassword.AutoSize = true;
- labelPassword.Location = new System.Drawing.Point(6, 23);
- labelPassword.Name = "labelPassword";
- labelPassword.Size = new System.Drawing.Size(53, 13);
- labelPassword.TabIndex = 0;
- labelPassword.Text = "Password";
- //
- // securityGroup
- //
- securityGroup.Controls.Add(this.passwordTextBox);
- securityGroup.Controls.Add(labelPassword);
- securityGroup.Location = new System.Drawing.Point(3, 263);
- securityGroup.Name = "securityGroup";
- securityGroup.Size = new System.Drawing.Size(306, 56);
- securityGroup.TabIndex = 10;
- securityGroup.TabStop = false;
- securityGroup.Text = "Encryption";
- //
- // passwordTextBox
- //
- this.passwordTextBox.Location = new System.Drawing.Point(65, 20);
- this.passwordTextBox.Name = "passwordTextBox";
- this.passwordTextBox.Size = new System.Drawing.Size(235, 21);
- this.passwordTextBox.TabIndex = 1;
- this.passwordTextBox.UseSystemPasswordChar = true;
- this.passwordTextBox.Leave += new System.EventHandler(this.passwordTextBox_Leave);
- //
- // encodingGroup
- //
- encodingGroup.Controls.Add(this.utf16RadioButton);
- encodingGroup.Controls.Add(this.utf8RadioButton);
- encodingGroup.Location = new System.Drawing.Point(3, 159);
- encodingGroup.Name = "encodingGroup";
- encodingGroup.Size = new System.Drawing.Size(75, 98);
- encodingGroup.TabIndex = 7;
- encodingGroup.TabStop = false;
- encodingGroup.Text = "Encoding";
- //
- // utf16RadioButton
- //
- this.utf16RadioButton.AutoSize = true;
- this.utf16RadioButton.Location = new System.Drawing.Point(6, 44);
- this.utf16RadioButton.Name = "utf16RadioButton";
- this.utf16RadioButton.Size = new System.Drawing.Size(60, 17);
- this.utf16RadioButton.TabIndex = 1;
- this.utf16RadioButton.TabStop = true;
- this.utf16RadioButton.Text = "UTF-16";
- this.utf16RadioButton.UseVisualStyleBackColor = true;
- this.utf16RadioButton.CheckedChanged += new System.EventHandler(this.encoding_Changed);
- //
- // utf8RadioButton
- //
- this.utf8RadioButton.AutoSize = true;
- this.utf8RadioButton.Checked = true;
- this.utf8RadioButton.Location = new System.Drawing.Point(7, 21);
- this.utf8RadioButton.Name = "utf8RadioButton";
- this.utf8RadioButton.Size = new System.Drawing.Size(54, 17);
- this.utf8RadioButton.TabIndex = 0;
- this.utf8RadioButton.TabStop = true;
- this.utf8RadioButton.Text = "UTF-8";
- this.utf8RadioButton.UseVisualStyleBackColor = true;
- this.utf8RadioButton.CheckedChanged += new System.EventHandler(this.encoding_Changed);
- //
- // dateTimeGroup
- //
- dateTimeGroup.Controls.Add(this.julianRadioButton);
- dateTimeGroup.Controls.Add(this.ticksRadioButton);
- dateTimeGroup.Controls.Add(this.iso8601RadioButton);
- dateTimeGroup.Location = new System.Drawing.Point(84, 159);
- dateTimeGroup.Name = "dateTimeGroup";
- dateTimeGroup.Size = new System.Drawing.Size(113, 98);
- dateTimeGroup.TabIndex = 8;
- dateTimeGroup.TabStop = false;
- dateTimeGroup.Text = "Date/Time Format";
- //
- // ticksRadioButton
- //
- this.ticksRadioButton.AutoSize = true;
- this.ticksRadioButton.Location = new System.Drawing.Point(7, 66);
- this.ticksRadioButton.Name = "ticksRadioButton";
- this.ticksRadioButton.Size = new System.Drawing.Size(48, 17);
- this.ticksRadioButton.TabIndex = 1;
- this.ticksRadioButton.TabStop = true;
- this.ticksRadioButton.Text = "Ticks";
- this.ticksRadioButton.UseVisualStyleBackColor = true;
- this.ticksRadioButton.CheckedChanged += new System.EventHandler(this.datetime_Changed);
- //
- // iso8601RadioButton
- //
- this.iso8601RadioButton.AutoSize = true;
- this.iso8601RadioButton.Checked = true;
- this.iso8601RadioButton.Location = new System.Drawing.Point(7, 21);
- this.iso8601RadioButton.Name = "iso8601RadioButton";
- this.iso8601RadioButton.Size = new System.Drawing.Size(71, 17);
- this.iso8601RadioButton.TabIndex = 0;
- this.iso8601RadioButton.TabStop = true;
- this.iso8601RadioButton.Text = "ISO-8601";
- this.iso8601RadioButton.UseVisualStyleBackColor = true;
- this.iso8601RadioButton.CheckedChanged += new System.EventHandler(this.datetime_Changed);
- //
- // databaseGroup
- //
- databaseGroup.Controls.Add(cacheSizeLabel);
- databaseGroup.Controls.Add(this.cacheSizeTextbox);
- databaseGroup.Controls.Add(pageSizeLabel);
- databaseGroup.Controls.Add(this.pageSizeTextBox);
- databaseGroup.Controls.Add(this.fileTextBox);
- databaseGroup.Controls.Add(this.browseButton);
- databaseGroup.Controls.Add(this.newDatabase);
- databaseGroup.Location = new System.Drawing.Point(3, 3);
- databaseGroup.Name = "databaseGroup";
- databaseGroup.Size = new System.Drawing.Size(306, 150);
- databaseGroup.TabIndex = 8;
- databaseGroup.TabStop = false;
- databaseGroup.Text = "Database";
- //
- // cacheSizeLabel
- //
- cacheSizeLabel.AutoSize = true;
- cacheSizeLabel.Location = new System.Drawing.Point(7, 116);
- cacheSizeLabel.Name = "cacheSizeLabel";
- cacheSizeLabel.Size = new System.Drawing.Size(59, 13);
- cacheSizeLabel.TabIndex = 5;
- cacheSizeLabel.Text = "Cache Size";
- //
- // cacheSizeTextbox
- //
- this.cacheSizeTextbox.Location = new System.Drawing.Point(72, 113);
- this.cacheSizeTextbox.Name = "cacheSizeTextbox";
- this.cacheSizeTextbox.Size = new System.Drawing.Size(100, 21);
- this.cacheSizeTextbox.TabIndex = 6;
- this.cacheSizeTextbox.Text = "2000";
- this.cacheSizeTextbox.Leave += new System.EventHandler(this.cacheSizeTextbox_Leave);
- //
- // pageSizeLabel
- //
- pageSizeLabel.AutoSize = true;
- pageSizeLabel.Location = new System.Drawing.Point(13, 89);
- pageSizeLabel.Name = "pageSizeLabel";
- pageSizeLabel.Size = new System.Drawing.Size(53, 13);
- pageSizeLabel.TabIndex = 3;
- pageSizeLabel.Text = "Page Size";
- //
- // pageSizeTextBox
- //
- this.pageSizeTextBox.Location = new System.Drawing.Point(72, 86);
- this.pageSizeTextBox.Name = "pageSizeTextBox";
- this.pageSizeTextBox.Size = new System.Drawing.Size(100, 21);
- this.pageSizeTextBox.TabIndex = 4;
- this.pageSizeTextBox.Text = "1024";
- this.pageSizeTextBox.Leave += new System.EventHandler(this.pageSizeTextBox_Leave);
- //
- // fileTextBox
- //
- this.fileTextBox.Location = new System.Drawing.Point(6, 20);
- this.fileTextBox.Name = "fileTextBox";
- this.fileTextBox.Size = new System.Drawing.Size(294, 21);
- this.fileTextBox.TabIndex = 0;
- this.fileTextBox.Leave += new System.EventHandler(this.fileTextBox_Leave);
- //
- // browseButton
- //
- this.browseButton.Location = new System.Drawing.Point(6, 47);
- this.browseButton.Name = "browseButton";
- this.browseButton.Size = new System.Drawing.Size(75, 23);
- this.browseButton.TabIndex = 1;
- this.browseButton.Text = "&Browse ...";
- this.browseButton.UseVisualStyleBackColor = true;
- this.browseButton.Click += new System.EventHandler(this.browseButton_Click);
- //
- // newDatabase
- //
- this.newDatabase.Location = new System.Drawing.Point(87, 47);
- this.newDatabase.Name = "newDatabase";
- this.newDatabase.Size = new System.Drawing.Size(75, 23);
- this.newDatabase.TabIndex = 2;
- this.newDatabase.Text = "&New ...";
- this.newDatabase.UseVisualStyleBackColor = true;
- this.newDatabase.Click += new System.EventHandler(this.newDatabase_Click);
- //
- // syncGroup
- //
- syncGroup.Controls.Add(this.offRadioButton);
- syncGroup.Controls.Add(this.normalRadioButton);
- syncGroup.Controls.Add(this.fullRadioButton);
- syncGroup.Location = new System.Drawing.Point(204, 159);
- syncGroup.Name = "syncGroup";
- syncGroup.Size = new System.Drawing.Size(105, 98);
- syncGroup.TabIndex = 9;
- syncGroup.TabStop = false;
- syncGroup.Text = "Synchronization";
- //
- // offRadioButton
- //
- this.offRadioButton.AutoSize = true;
- this.offRadioButton.Location = new System.Drawing.Point(6, 66);
- this.offRadioButton.Name = "offRadioButton";
- this.offRadioButton.Size = new System.Drawing.Size(41, 17);
- this.offRadioButton.TabIndex = 2;
- this.offRadioButton.Text = "Off";
- this.offRadioButton.UseVisualStyleBackColor = true;
- this.offRadioButton.CheckedChanged += new System.EventHandler(this.sync_Changed);
- //
- // normalRadioButton
- //
- this.normalRadioButton.AutoSize = true;
- this.normalRadioButton.Checked = true;
- this.normalRadioButton.Location = new System.Drawing.Point(6, 43);
- this.normalRadioButton.Name = "normalRadioButton";
- this.normalRadioButton.Size = new System.Drawing.Size(58, 17);
- this.normalRadioButton.TabIndex = 1;
- this.normalRadioButton.TabStop = true;
- this.normalRadioButton.Text = "Normal";
- this.normalRadioButton.UseVisualStyleBackColor = true;
- this.normalRadioButton.CheckedChanged += new System.EventHandler(this.sync_Changed);
- //
- // fullRadioButton
- //
- this.fullRadioButton.AutoSize = true;
- this.fullRadioButton.Location = new System.Drawing.Point(6, 20);
- this.fullRadioButton.Name = "fullRadioButton";
- this.fullRadioButton.Size = new System.Drawing.Size(41, 17);
- this.fullRadioButton.TabIndex = 0;
- this.fullRadioButton.Text = "Full";
- this.fullRadioButton.UseVisualStyleBackColor = true;
- this.fullRadioButton.CheckedChanged += new System.EventHandler(this.sync_Changed);
- //
- // julianRadioButton
- //
- this.julianRadioButton.AutoSize = true;
- this.julianRadioButton.Location = new System.Drawing.Point(7, 44);
- this.julianRadioButton.Name = "julianRadioButton";
- this.julianRadioButton.Size = new System.Drawing.Size(74, 17);
- this.julianRadioButton.TabIndex = 2;
- this.julianRadioButton.TabStop = true;
- this.julianRadioButton.Text = "Julian Day";
- this.julianRadioButton.UseVisualStyleBackColor = true;
- this.julianRadioButton.CheckedChanged += new System.EventHandler(this.datetime_Changed);
- //
- // SQLiteConnectionUIControl
- //
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit;
- this.Controls.Add(syncGroup);
- this.Controls.Add(databaseGroup);
- this.Controls.Add(dateTimeGroup);
- this.Controls.Add(encodingGroup);
- this.Controls.Add(securityGroup);
- this.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.Name = "SQLiteConnectionUIControl";
- this.Size = new System.Drawing.Size(312, 322);
- securityGroup.ResumeLayout(false);
- securityGroup.PerformLayout();
- encodingGroup.ResumeLayout(false);
- encodingGroup.PerformLayout();
- dateTimeGroup.ResumeLayout(false);
- dateTimeGroup.PerformLayout();
- databaseGroup.ResumeLayout(false);
- databaseGroup.PerformLayout();
- syncGroup.ResumeLayout(false);
- syncGroup.PerformLayout();
- this.ResumeLayout(false);
-
- }
-
- #endregion
-
- private System.Windows.Forms.TextBox fileTextBox;
- private System.Windows.Forms.Button browseButton;
- private System.Windows.Forms.Button newDatabase;
- private System.Windows.Forms.TextBox passwordTextBox;
- private System.Windows.Forms.RadioButton utf16RadioButton;
- private System.Windows.Forms.RadioButton utf8RadioButton;
- private System.Windows.Forms.RadioButton ticksRadioButton;
- private System.Windows.Forms.RadioButton iso8601RadioButton;
- private System.Windows.Forms.TextBox pageSizeTextBox;
- private System.Windows.Forms.TextBox cacheSizeTextbox;
- private System.Windows.Forms.RadioButton offRadioButton;
- private System.Windows.Forms.RadioButton normalRadioButton;
- private System.Windows.Forms.RadioButton fullRadioButton;
- private System.Windows.Forms.RadioButton julianRadioButton;
- }
+ ********************************************************/
+
+namespace SQLite.Designer
+{
+ partial class SQLiteConnectionUIControl
+ {
+ ///
+ /// Required designer variable.
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// Clean up any resources being used.
+ ///
+ /// true if managed resources should be disposed; otherwise, false.
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region Windows Form Designer generated code
+ ///
+ /// Required method for Designer support - do not modify
+ /// the contents of this method with the code editor.
+ ///
+ private void InitializeComponent()
+ {
+ System.Windows.Forms.Label labelPassword;
+ System.Windows.Forms.GroupBox securityGroup;
+ System.Windows.Forms.GroupBox encodingGroup;
+ System.Windows.Forms.GroupBox dateTimeGroup;
+ System.Windows.Forms.GroupBox databaseGroup;
+ System.Windows.Forms.Label cacheSizeLabel;
+ System.Windows.Forms.Label pageSizeLabel;
+ System.Windows.Forms.GroupBox syncGroup;
+ System.Windows.Forms.GroupBox providerGroup;
+ this.passwordTextBox = new System.Windows.Forms.TextBox();
+ this.utf16RadioButton = new System.Windows.Forms.RadioButton();
+ this.utf8RadioButton = new System.Windows.Forms.RadioButton();
+ this.ticksRadioButton = new System.Windows.Forms.RadioButton();
+ this.iso8601RadioButton = new System.Windows.Forms.RadioButton();
+ this.cacheSizeTextbox = new System.Windows.Forms.TextBox();
+ this.pageSizeTextBox = new System.Windows.Forms.TextBox();
+ this.fileTextBox = new System.Windows.Forms.TextBox();
+ this.browseButton = new System.Windows.Forms.Button();
+ this.newDatabase = new System.Windows.Forms.Button();
+ this.offRadioButton = new System.Windows.Forms.RadioButton();
+ this.normalRadioButton = new System.Windows.Forms.RadioButton();
+ this.fullRadioButton = new System.Windows.Forms.RadioButton();
+ this.julianRadioButton = new System.Windows.Forms.RadioButton();
+ this.providerComboBox = new System.Windows.Forms.ComboBox();
+ labelPassword = new System.Windows.Forms.Label();
+ securityGroup = new System.Windows.Forms.GroupBox();
+ encodingGroup = new System.Windows.Forms.GroupBox();
+ dateTimeGroup = new System.Windows.Forms.GroupBox();
+ databaseGroup = new System.Windows.Forms.GroupBox();
+ cacheSizeLabel = new System.Windows.Forms.Label();
+ pageSizeLabel = new System.Windows.Forms.Label();
+ syncGroup = new System.Windows.Forms.GroupBox();
+ providerGroup = new System.Windows.Forms.GroupBox();
+ securityGroup.SuspendLayout();
+ encodingGroup.SuspendLayout();
+ dateTimeGroup.SuspendLayout();
+ databaseGroup.SuspendLayout();
+ syncGroup.SuspendLayout();
+ providerGroup.SuspendLayout();
+ this.SuspendLayout();
+ //
+ // labelPassword
+ //
+ labelPassword.AutoSize = true;
+ labelPassword.Location = new System.Drawing.Point(6, 23);
+ labelPassword.Name = "labelPassword";
+ labelPassword.Size = new System.Drawing.Size(53, 13);
+ labelPassword.TabIndex = 0;
+ labelPassword.Text = "Password";
+ //
+ // securityGroup
+ //
+ securityGroup.Controls.Add(this.passwordTextBox);
+ securityGroup.Controls.Add(labelPassword);
+ securityGroup.Location = new System.Drawing.Point(3, 263);
+ securityGroup.Name = "securityGroup";
+ securityGroup.Size = new System.Drawing.Size(306, 56);
+ securityGroup.TabIndex = 10;
+ securityGroup.TabStop = false;
+ securityGroup.Text = "Encryption";
+ //
+ // passwordTextBox
+ //
+ this.passwordTextBox.Location = new System.Drawing.Point(65, 20);
+ this.passwordTextBox.Name = "passwordTextBox";
+ this.passwordTextBox.Size = new System.Drawing.Size(235, 21);
+ this.passwordTextBox.TabIndex = 1;
+ this.passwordTextBox.UseSystemPasswordChar = true;
+ this.passwordTextBox.Leave += new System.EventHandler(this.passwordTextBox_Leave);
+ //
+ // encodingGroup
+ //
+ encodingGroup.Controls.Add(this.utf16RadioButton);
+ encodingGroup.Controls.Add(this.utf8RadioButton);
+ encodingGroup.Location = new System.Drawing.Point(3, 159);
+ encodingGroup.Name = "encodingGroup";
+ encodingGroup.Size = new System.Drawing.Size(75, 98);
+ encodingGroup.TabIndex = 7;
+ encodingGroup.TabStop = false;
+ encodingGroup.Text = "Encoding";
+ //
+ // utf16RadioButton
+ //
+ this.utf16RadioButton.AutoSize = true;
+ this.utf16RadioButton.Location = new System.Drawing.Point(6, 44);
+ this.utf16RadioButton.Name = "utf16RadioButton";
+ this.utf16RadioButton.Size = new System.Drawing.Size(60, 17);
+ this.utf16RadioButton.TabIndex = 1;
+ this.utf16RadioButton.TabStop = true;
+ this.utf16RadioButton.Text = "UTF-16";
+ this.utf16RadioButton.UseVisualStyleBackColor = true;
+ this.utf16RadioButton.CheckedChanged += new System.EventHandler(this.encoding_Changed);
+ //
+ // utf8RadioButton
+ //
+ this.utf8RadioButton.AutoSize = true;
+ this.utf8RadioButton.Checked = true;
+ this.utf8RadioButton.Location = new System.Drawing.Point(7, 21);
+ this.utf8RadioButton.Name = "utf8RadioButton";
+ this.utf8RadioButton.Size = new System.Drawing.Size(54, 17);
+ this.utf8RadioButton.TabIndex = 0;
+ this.utf8RadioButton.TabStop = true;
+ this.utf8RadioButton.Text = "UTF-8";
+ this.utf8RadioButton.UseVisualStyleBackColor = true;
+ this.utf8RadioButton.CheckedChanged += new System.EventHandler(this.encoding_Changed);
+ //
+ // dateTimeGroup
+ //
+ dateTimeGroup.Controls.Add(this.julianRadioButton);
+ dateTimeGroup.Controls.Add(this.ticksRadioButton);
+ dateTimeGroup.Controls.Add(this.iso8601RadioButton);
+ dateTimeGroup.Location = new System.Drawing.Point(84, 159);
+ dateTimeGroup.Name = "dateTimeGroup";
+ dateTimeGroup.Size = new System.Drawing.Size(113, 98);
+ dateTimeGroup.TabIndex = 8;
+ dateTimeGroup.TabStop = false;
+ dateTimeGroup.Text = "Date/Time Format";
+ //
+ // ticksRadioButton
+ //
+ this.ticksRadioButton.AutoSize = true;
+ this.ticksRadioButton.Location = new System.Drawing.Point(7, 66);
+ this.ticksRadioButton.Name = "ticksRadioButton";
+ this.ticksRadioButton.Size = new System.Drawing.Size(48, 17);
+ this.ticksRadioButton.TabIndex = 1;
+ this.ticksRadioButton.TabStop = true;
+ this.ticksRadioButton.Text = "Ticks";
+ this.ticksRadioButton.UseVisualStyleBackColor = true;
+ this.ticksRadioButton.CheckedChanged += new System.EventHandler(this.datetime_Changed);
+ //
+ // iso8601RadioButton
+ //
+ this.iso8601RadioButton.AutoSize = true;
+ this.iso8601RadioButton.Checked = true;
+ this.iso8601RadioButton.Location = new System.Drawing.Point(7, 21);
+ this.iso8601RadioButton.Name = "iso8601RadioButton";
+ this.iso8601RadioButton.Size = new System.Drawing.Size(71, 17);
+ this.iso8601RadioButton.TabIndex = 0;
+ this.iso8601RadioButton.TabStop = true;
+ this.iso8601RadioButton.Text = "ISO-8601";
+ this.iso8601RadioButton.UseVisualStyleBackColor = true;
+ this.iso8601RadioButton.CheckedChanged += new System.EventHandler(this.datetime_Changed);
+ //
+ // databaseGroup
+ //
+ databaseGroup.Controls.Add(cacheSizeLabel);
+ databaseGroup.Controls.Add(this.cacheSizeTextbox);
+ databaseGroup.Controls.Add(pageSizeLabel);
+ databaseGroup.Controls.Add(this.pageSizeTextBox);
+ databaseGroup.Controls.Add(this.fileTextBox);
+ databaseGroup.Controls.Add(this.browseButton);
+ databaseGroup.Controls.Add(this.newDatabase);
+ databaseGroup.Location = new System.Drawing.Point(3, 3);
+ databaseGroup.Name = "databaseGroup";
+ databaseGroup.Size = new System.Drawing.Size(306, 150);
+ databaseGroup.TabIndex = 8;
+ databaseGroup.TabStop = false;
+ databaseGroup.Text = "Database";
+ //
+ // cacheSizeLabel
+ //
+ cacheSizeLabel.AutoSize = true;
+ cacheSizeLabel.Location = new System.Drawing.Point(7, 116);
+ cacheSizeLabel.Name = "cacheSizeLabel";
+ cacheSizeLabel.Size = new System.Drawing.Size(59, 13);
+ cacheSizeLabel.TabIndex = 5;
+ cacheSizeLabel.Text = "Cache Size";
+ //
+ // cacheSizeTextbox
+ //
+ this.cacheSizeTextbox.Location = new System.Drawing.Point(72, 113);
+ this.cacheSizeTextbox.Name = "cacheSizeTextbox";
+ this.cacheSizeTextbox.Size = new System.Drawing.Size(100, 21);
+ this.cacheSizeTextbox.TabIndex = 6;
+ this.cacheSizeTextbox.Text = "2000";
+ this.cacheSizeTextbox.Leave += new System.EventHandler(this.cacheSizeTextbox_Leave);
+ //
+ // pageSizeLabel
+ //
+ pageSizeLabel.AutoSize = true;
+ pageSizeLabel.Location = new System.Drawing.Point(13, 89);
+ pageSizeLabel.Name = "pageSizeLabel";
+ pageSizeLabel.Size = new System.Drawing.Size(53, 13);
+ pageSizeLabel.TabIndex = 3;
+ pageSizeLabel.Text = "Page Size";
+ //
+ // pageSizeTextBox
+ //
+ this.pageSizeTextBox.Location = new System.Drawing.Point(72, 86);
+ this.pageSizeTextBox.Name = "pageSizeTextBox";
+ this.pageSizeTextBox.Size = new System.Drawing.Size(100, 21);
+ this.pageSizeTextBox.TabIndex = 4;
+ this.pageSizeTextBox.Text = "1024";
+ this.pageSizeTextBox.Leave += new System.EventHandler(this.pageSizeTextBox_Leave);
+ //
+ // fileTextBox
+ //
+ this.fileTextBox.Location = new System.Drawing.Point(6, 20);
+ this.fileTextBox.Name = "fileTextBox";
+ this.fileTextBox.Size = new System.Drawing.Size(294, 21);
+ this.fileTextBox.TabIndex = 0;
+ this.fileTextBox.Leave += new System.EventHandler(this.fileTextBox_Leave);
+ //
+ // browseButton
+ //
+ this.browseButton.Location = new System.Drawing.Point(6, 47);
+ this.browseButton.Name = "browseButton";
+ this.browseButton.Size = new System.Drawing.Size(75, 23);
+ this.browseButton.TabIndex = 1;
+ this.browseButton.Text = "&Browse ...";
+ this.browseButton.UseVisualStyleBackColor = true;
+ this.browseButton.Click += new System.EventHandler(this.browseButton_Click);
+ //
+ // newDatabase
+ //
+ this.newDatabase.Location = new System.Drawing.Point(87, 47);
+ this.newDatabase.Name = "newDatabase";
+ this.newDatabase.Size = new System.Drawing.Size(75, 23);
+ this.newDatabase.TabIndex = 2;
+ this.newDatabase.Text = "&New ...";
+ this.newDatabase.UseVisualStyleBackColor = true;
+ this.newDatabase.Click += new System.EventHandler(this.newDatabase_Click);
+ //
+ // syncGroup
+ //
+ syncGroup.Controls.Add(this.offRadioButton);
+ syncGroup.Controls.Add(this.normalRadioButton);
+ syncGroup.Controls.Add(this.fullRadioButton);
+ syncGroup.Location = new System.Drawing.Point(204, 159);
+ syncGroup.Name = "syncGroup";
+ syncGroup.Size = new System.Drawing.Size(105, 98);
+ syncGroup.TabIndex = 9;
+ syncGroup.TabStop = false;
+ syncGroup.Text = "Synchronization";
+ //
+ // offRadioButton
+ //
+ this.offRadioButton.AutoSize = true;
+ this.offRadioButton.Location = new System.Drawing.Point(6, 66);
+ this.offRadioButton.Name = "offRadioButton";
+ this.offRadioButton.Size = new System.Drawing.Size(41, 17);
+ this.offRadioButton.TabIndex = 2;
+ this.offRadioButton.Text = "Off";
+ this.offRadioButton.UseVisualStyleBackColor = true;
+ this.offRadioButton.CheckedChanged += new System.EventHandler(this.sync_Changed);
+ //
+ // normalRadioButton
+ //
+ this.normalRadioButton.AutoSize = true;
+ this.normalRadioButton.Checked = true;
+ this.normalRadioButton.Location = new System.Drawing.Point(6, 43);
+ this.normalRadioButton.Name = "normalRadioButton";
+ this.normalRadioButton.Size = new System.Drawing.Size(58, 17);
+ this.normalRadioButton.TabIndex = 1;
+ this.normalRadioButton.TabStop = true;
+ this.normalRadioButton.Text = "Normal";
+ this.normalRadioButton.UseVisualStyleBackColor = true;
+ this.normalRadioButton.CheckedChanged += new System.EventHandler(this.sync_Changed);
+ //
+ // fullRadioButton
+ //
+ this.fullRadioButton.AutoSize = true;
+ this.fullRadioButton.Location = new System.Drawing.Point(6, 20);
+ this.fullRadioButton.Name = "fullRadioButton";
+ this.fullRadioButton.Size = new System.Drawing.Size(41, 17);
+ this.fullRadioButton.TabIndex = 0;
+ this.fullRadioButton.Text = "Full";
+ this.fullRadioButton.UseVisualStyleBackColor = true;
+ this.fullRadioButton.CheckedChanged += new System.EventHandler(this.sync_Changed);
+ //
+ // julianRadioButton
+ //
+ this.julianRadioButton.AutoSize = true;
+ this.julianRadioButton.Location = new System.Drawing.Point(7, 44);
+ this.julianRadioButton.Name = "julianRadioButton";
+ this.julianRadioButton.Size = new System.Drawing.Size(74, 17);
+ this.julianRadioButton.TabIndex = 2;
+ this.julianRadioButton.TabStop = true;
+ this.julianRadioButton.Text = "Julian Day";
+ this.julianRadioButton.UseVisualStyleBackColor = true;
+ this.julianRadioButton.CheckedChanged += new System.EventHandler(this.datetime_Changed);
+ //
+ // providerGroup
+ //
+ providerGroup.Controls.Add(this.providerComboBox);
+ providerGroup.Location = new System.Drawing.Point(3, 325);
+ providerGroup.Name = "providerGroup";
+ providerGroup.Size = new System.Drawing.Size(306, 56);
+ providerGroup.TabIndex = 11;
+ providerGroup.TabStop = false;
+ providerGroup.Text = "Provider";
+ //
+ // providerComboBox
+ //
+ this.providerComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.providerComboBox.FormattingEnabled = true;
+ this.providerComboBox.Location = new System.Drawing.Point(6, 20);
+ this.providerComboBox.Name = "providerComboBox";
+ this.providerComboBox.Size = new System.Drawing.Size(294, 21);
+ this.providerComboBox.TabIndex = 0;
+ this.providerComboBox.SelectedIndexChanged += new System.EventHandler(this.provider_Changed);
+ //
+ // SQLiteConnectionUIControl
+ //
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit;
+ this.Controls.Add(providerGroup);
+ this.Controls.Add(syncGroup);
+ this.Controls.Add(databaseGroup);
+ this.Controls.Add(dateTimeGroup);
+ this.Controls.Add(encodingGroup);
+ this.Controls.Add(securityGroup);
+ this.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.Name = "SQLiteConnectionUIControl";
+ this.Size = new System.Drawing.Size(312, 386);
+ securityGroup.ResumeLayout(false);
+ securityGroup.PerformLayout();
+ encodingGroup.ResumeLayout(false);
+ encodingGroup.PerformLayout();
+ dateTimeGroup.ResumeLayout(false);
+ dateTimeGroup.PerformLayout();
+ databaseGroup.ResumeLayout(false);
+ databaseGroup.PerformLayout();
+ syncGroup.ResumeLayout(false);
+ syncGroup.PerformLayout();
+ providerGroup.ResumeLayout(false);
+ this.ResumeLayout(false);
+ }
+ #endregion
+
+ private System.Windows.Forms.TextBox fileTextBox;
+ private System.Windows.Forms.Button browseButton;
+ private System.Windows.Forms.Button newDatabase;
+ private System.Windows.Forms.TextBox passwordTextBox;
+ private System.Windows.Forms.RadioButton utf16RadioButton;
+ private System.Windows.Forms.RadioButton utf8RadioButton;
+ private System.Windows.Forms.RadioButton ticksRadioButton;
+ private System.Windows.Forms.RadioButton iso8601RadioButton;
+ private System.Windows.Forms.TextBox pageSizeTextBox;
+ private System.Windows.Forms.TextBox cacheSizeTextbox;
+ private System.Windows.Forms.RadioButton offRadioButton;
+ private System.Windows.Forms.RadioButton normalRadioButton;
+ private System.Windows.Forms.RadioButton fullRadioButton;
+ private System.Windows.Forms.RadioButton julianRadioButton;
+ private System.Windows.Forms.ComboBox providerComboBox;
+ }
}
Index: SQLite.Designer/SQLiteConnectionUIControl.cs
==================================================================
--- SQLite.Designer/SQLiteConnectionUIControl.cs
+++ SQLite.Designer/SQLiteConnectionUIControl.cs
@@ -1,24 +1,19 @@
/********************************************************
* ADO.NET 2.0 Data Provider for SQLite Version 3.X
* Written by Robert Simpson (robert@blackcastlesoft.com)
- *
+ *
* Released to the public domain, use at your own risk!
********************************************************/
namespace SQLite.Designer
{
using System;
- using System.Collections.Generic;
using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Text;
using System.Windows.Forms;
using System.Globalization;
using Microsoft.VisualStudio.Data;
- using Microsoft.Win32;
///
/// Provides a UI to edit/create SQLite database connections
///
[ToolboxItem(false)]
@@ -25,10 +20,11 @@
public partial class SQLiteConnectionUIControl : DataConnectionUIControl
{
public SQLiteConnectionUIControl()
{
InitializeComponent();
+ SQLiteOptions.AddProviderNames(providerComboBox.Items);
}
private void browseButton_Click(object sender, EventArgs e)
{
OpenFileDialog dlg = new OpenFileDialog();
@@ -55,51 +51,75 @@
#region IDataConnectionUIControl Members
public override void LoadProperties()
{
+ SQLiteOptions.SelectProviderName(providerComboBox);
+
+ fileTextBox.Text = String.Empty;
+ passwordTextBox.Text = String.Empty;
+
+ if (ConnectionProperties == null)
+ return;
+
if (ConnectionProperties.Contains("data source"))
fileTextBox.Text = ConnectionProperties["data source"] as string;
- else
- fileTextBox.Text = String.Empty;
if (ConnectionProperties.Contains("password"))
passwordTextBox.Text = ConnectionProperties["password"] as string;
- else
- passwordTextBox.Text = String.Empty;
}
#endregion
private void passwordTextBox_Leave(object sender, EventArgs e)
{
+ if (ConnectionProperties == null)
+ return;
+
if (String.IsNullOrEmpty(passwordTextBox.Text))
ConnectionProperties.Remove("password");
else
ConnectionProperties["password"] = passwordTextBox.Text;
}
private void encoding_Changed(object sender, EventArgs e)
{
+ if (ConnectionProperties == null)
+ return;
+
if (utf8RadioButton.Checked == true)
ConnectionProperties.Remove("useutf16encoding");
else
ConnectionProperties["useutf16encoding"] = utf16RadioButton.Checked;
}
private void datetime_Changed(object sender, EventArgs e)
{
+ if (ConnectionProperties == null)
+ return;
+
if (iso8601RadioButton.Checked == true)
ConnectionProperties.Remove("datetimeformat");
else if (ticksRadioButton.Checked == true)
ConnectionProperties["datetimeformat"] = "Ticks";
else
ConnectionProperties["datetimeformat"] = "JulianDay";
}
+
+ private void provider_Changed(object sender, EventArgs e)
+ {
+ object item = providerComboBox.SelectedItem;
+
+ if (item != null)
+ SQLiteOptions.SetProviderName(item.ToString());
+ }
private void sync_Changed(object sender, EventArgs e)
{
+ if (ConnectionProperties == null)
+ return;
+
string sync = "Normal";
if (fullRadioButton.Checked == true) sync = "Full";
else if (offRadioButton.Checked == true) sync = "Off";
if (sync == "Normal")
@@ -108,21 +128,30 @@
ConnectionProperties["synchronous"] = sync;
}
private void pageSizeTextBox_Leave(object sender, EventArgs e)
{
+ if (ConnectionProperties == null)
+ return;
+
int n = Convert.ToInt32(pageSizeTextBox.Text, CultureInfo.CurrentCulture);
ConnectionProperties["page size"] = n;
}
private void cacheSizeTextbox_Leave(object sender, EventArgs e)
{
+ if (ConnectionProperties == null)
+ return;
+
int n = Convert.ToInt32(cacheSizeTextbox.Text, CultureInfo.CurrentCulture);
ConnectionProperties["cache size"] = n;
}
private void fileTextBox_Leave(object sender, EventArgs e)
{
+ if (ConnectionProperties == null)
+ return;
+
ConnectionProperties["data source"] = fileTextBox.Text;
}
}
}
Index: SQLite.Designer/SQLiteConnectionUIControl.resx
==================================================================
--- SQLite.Designer/SQLiteConnectionUIControl.resx
+++ SQLite.Designer/SQLiteConnectionUIControl.resx
@@ -1,144 +1,147 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- False
-
-
- False
-
-
- False
-
-
- False
-
-
- False
-
-
- False
-
-
- False
-
-
- False
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ False
+
+
+ False
+
+
+ False
+
+
+ False
+
+
+ False
+
+
+ False
+
+
+ False
+
+
+ False
+
+
+ False
+
Index: SQLite.Designer/SQLiteDataAdapterToolboxItem.cs
==================================================================
--- SQLite.Designer/SQLiteDataAdapterToolboxItem.cs
+++ SQLite.Designer/SQLiteDataAdapterToolboxItem.cs
@@ -61,11 +61,11 @@
///
/// The designer host
/// The components created by this toolbox item
protected override IComponent[] CreateComponentsCore(IDesignerHost host)
{
- DbProviderFactory fact = DbProviderFactories.GetFactory("System.Data.SQLite");
+ DbProviderFactory fact = DbProviderFactories.GetFactory(SQLiteOptions.GetProviderName());
DbDataAdapter dataAdapter = fact.CreateDataAdapter();
IContainer container = host.Container;
using (DbCommand adapterCommand = fact.CreateCommand())
Index: SQLite.Designer/SQLiteDataConnectionSupport.cs
==================================================================
--- SQLite.Designer/SQLiteDataConnectionSupport.cs
+++ SQLite.Designer/SQLiteDataConnectionSupport.cs
@@ -21,11 +21,11 @@
private SQLiteDataViewSupport _dataViewSupport;
private SQLiteDataObjectSupport _dataObjectSupport;
private SQLiteDataObjectIdentifierResolver _dataObjectIdentifierResolver;
public SQLiteDataConnectionSupport()
- : base("System.Data.SQLite")
+ : base(SQLiteOptions.GetProviderName())
{
}
protected override DataSourceInformation CreateDataSourceInformation()
{
ADDED SQLite.Designer/SQLiteOptions.cs
Index: SQLite.Designer/SQLiteOptions.cs
==================================================================
--- /dev/null
+++ SQLite.Designer/SQLiteOptions.cs
@@ -0,0 +1,585 @@
+/********************************************************
+ * ADO.NET 2.0 Data Provider for SQLite Version 3.X
+ * Written by Joe Mistachkin (joe@mistachkin.com)
+ *
+ * Released to the public domain, use at your own risk!
+ ********************************************************/
+
+using System;
+using System.Collections.Generic;
+using System.Data.Common;
+using System.IO;
+using System.Runtime.InteropServices;
+using System.Windows.Forms;
+using Microsoft.VisualStudio.Shell;
+
+namespace SQLite.Designer
+{
+ ///
+ /// This class keeps track of the options configured on a per-solution file
+ /// basis pertaining to the System.Data.SQLite design-time components.
+ ///
+ [Guid("5cf5656c-ccbe-4162-8780-0cbee936b90c")]
+ internal static class SQLiteOptions
+ {
+ #region Private Constants
+ ///
+ /// This is the name of the setting containing the configured ADO.NET
+ /// provider name.
+ ///
+ private static readonly string ProviderNameKey = "ProviderName";
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This is the name of the environment variable that will be checked
+ /// prior to setting the initial default value for the configured
+ /// ADO.NET provider name, thus allowing the default value to be
+ /// overridden via the environment.
+ ///
+ private static readonly string ProviderNameEnvVarName =
+ "ProviderName_SQLiteDesigner";
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This is the legacy provider name used by the System.Data.SQLite
+ /// design-time components. It is also the default value for the
+ /// associated option key.
+ ///
+ private static readonly string DefaultProviderName = "System.Data.SQLite";
+
+ ///////////////////////////////////////////////////////////////////////
+
+#if NET_40 || NET_45 || NET_451
+ ///
+ /// This is the provider name used when Entity Framework 6.x support is
+ /// required for use with the System.Data.SQLite design-time components.
+ /// This provider name is only available when this class is compiled for
+ /// the .NET Framework 4.0 or later.
+ ///
+ private static readonly string Ef6ProviderName = "System.Data.SQLite.EF6";
+#endif
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Private Static Data
+ ///
+ /// This is used to synchronize access to the static dictionary of
+ /// options (just below).
+ ///
+ private static readonly object syncRoot = new object();
+
+ ///
+ /// This dictionary contains the key/value pairs representing the
+ /// per-solution options configured for the current solution. When
+ /// a new solution is loaded by Visual Studio, this dictionary must
+ /// be reset.
+ ///
+ private static Dictionary options;
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Private Static Methods
+ ///
+ /// This method initializes (or resets) the per-solution configuration
+ /// options.
+ ///
+ ///
+ /// Non-zero to reset the options if they are already initialized.
+ /// When this method is called from the
+ /// constructor, this value should always be true.
+ ///
+ private static void Initialize(
+ bool reset
+ )
+ {
+ lock (syncRoot)
+ {
+ if (options != null)
+ options.Clear();
+ else
+ options = new Dictionary();
+
+ string key = ProviderNameKey;
+ string value = Environment.GetEnvironmentVariable(
+ ProviderNameEnvVarName);
+
+ if (IsValidValue(key, value))
+ options[key] = value;
+ else
+ options[key] = DefaultProviderName;
+ }
+ }
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Public Static Methods
+ #region Provider Name Handling
+ ///
+ /// This method determines the name of the ADO.NET provider for the
+ /// System.Data.SQLite design-time components to use.
+ ///
+ ///
+ /// The configured ADO.NET provider name for System.Data.SQLite -OR-
+ /// the default ADO.NET provider name for System.Data.SQLite in the
+ /// event of any failure. This method cannot return null.
+ ///
+ public static string GetProviderName()
+ {
+ return GetProviderName(DefaultProviderName);
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method determines the name of the ADO.NET provider for the
+ /// System.Data.SQLite design-time components to use.
+ ///
+ ///
+ /// The value to return from this method if the name of the ADO.NET
+ /// provider is unavailable -OR- cannot be determined.
+ ///
+ ///
+ /// The configured ADO.NET provider name for System.Data.SQLite -OR-
+ /// the default ADO.NET provider name for System.Data.SQLite in the
+ /// event of any failure.
+ ///
+ private static string GetProviderName(
+ string @default
+ )
+ {
+ string key = ProviderNameKey;
+ string value;
+
+ if (GetValue(key, out value) && IsValidValue(key, value))
+ return value;
+
+ return @default;
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method attempts to set the name of the ADO.NET provider for
+ /// the System.Data.SQLite design-time components to use.
+ ///
+ ///
+ /// The ADO.NET provider name to use.
+ ///
+ ///
+ /// Non-zero upon success; otherwise, zero. All ADO.NET provider names
+ /// unknown to this class are rejected.
+ ///
+ public static bool SetProviderName(
+ string value
+ )
+ {
+ string key = ProviderNameKey;
+
+ if (IsValidValue(key, value))
+ return SetValue(key, value);
+
+ return false;
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region User-Interface Handling
+ ///
+ /// This method attempts to select the configured ADO.NET provider name
+ /// in the specified . This method will only
+ /// work correctly when called from the user-interface thread.
+ ///
+ ///
+ /// The object where the selection is to be
+ /// modified.
+ ///
+ ///
+ /// Non-zero upon success; otherwise, zero.
+ ///
+ public static bool SelectProviderName(
+ ComboBox comboBox
+ )
+ {
+ if (comboBox == null)
+ return false;
+
+ string value = GetProviderName(null);
+
+ for (int index = 0; index < comboBox.Items.Count; index++)
+ {
+ object item = comboBox.Items[index];
+
+ if (item == null)
+ continue;
+
+ if ((value == null) || String.Equals(
+ item.ToString(), value, StringComparison.Ordinal))
+ {
+ comboBox.SelectedIndex = index;
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ private static bool CheckProviderName(
+ string name
+ )
+ {
+ DbProviderFactory dbProviderFactory = null;
+
+ try
+ {
+ dbProviderFactory = DbProviderFactories.GetFactory(
+ name); /* throw */
+
+ return (dbProviderFactory != null);
+ }
+ catch
+ {
+ // do nothing.
+ }
+ finally
+ {
+ if (dbProviderFactory != null)
+ {
+ IDisposable disposable = dbProviderFactory as IDisposable;
+
+ if (disposable != null)
+ {
+ disposable.Dispose();
+ disposable = null;
+ }
+
+ dbProviderFactory = null;
+ }
+ }
+
+ return false;
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method populates the specified item
+ /// list with the recognized ADO.NET provider names. This method will
+ /// only work correctly when called from the user-interface thread.
+ ///
+ ///
+ /// The property value containing the
+ /// list of items to be modified. This value cannot be null.
+ ///
+ ///
+ /// The number of items actually added to the list, which may be zero.
+ ///
+ public static int AddProviderNames(
+ ComboBox.ObjectCollection items
+ )
+ {
+ int result = 0;
+
+ if (items == null)
+ return result;
+
+ IList names = new List();
+
+#if NET_40 || NET_45 || NET_451
+ names.Add(Ef6ProviderName);
+#endif
+
+ names.Add(DefaultProviderName);
+
+ foreach (string name in names)
+ {
+ if (CheckProviderName(name))
+ {
+ items.Add(name);
+ result++;
+ }
+ }
+
+ return result;
+ }
+ #endregion
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Hard-Coded Default Value Handling
+ ///
+ /// This method determines if the specified key/value pair represents
+ /// the default value for that option.
+ ///
+ ///
+ /// The name ("key") of the configuration option.
+ ///
+ ///
+ /// The value of the configuration option.
+ ///
+ ///
+ /// Non-zero if the key/value pair represents its default value.
+ ///
+ public static bool IsDefaultValue(
+ string key,
+ string value
+ )
+ {
+ if (String.Equals(
+ key, ProviderNameKey, StringComparison.Ordinal) &&
+ String.Equals(
+ value, DefaultProviderName, StringComparison.Ordinal))
+ {
+ return true;
+ }
+
+ return false;
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method determines if the specified key/value pair is valid
+ /// and supported by this class.
+ ///
+ ///
+ /// The name ("key") of the configuration option.
+ ///
+ ///
+ /// The value of the configuration option.
+ ///
+ ///
+ /// Non-zero if the key/value pair represents a valid option key and
+ /// value supported by this class.
+ ///
+ public static bool IsValidValue(
+ string key,
+ string value
+ )
+ {
+ if (String.Equals(
+ key, ProviderNameKey, StringComparison.Ordinal) &&
+ (String.Equals(
+ value, DefaultProviderName, StringComparison.Ordinal)
+#if NET_40 || NET_45 || NET_451
+ || String.Equals(
+ value, Ef6ProviderName, StringComparison.Ordinal)
+#endif
+ ))
+ {
+ return true;
+ }
+
+ return false;
+ }
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Core Option Handling
+ ///
+ /// This method returns the current list of option keys supported by
+ /// the System.Data.SQLite design-time components.
+ ///
+ ///
+ /// An of strings containing the list of
+ /// option keys supported by the System.Data.SQLite design-time
+ /// components -OR- null in the event of any failure.
+ ///
+ public static IEnumerable GetKeys(
+ bool reset
+ )
+ {
+ lock (syncRoot) /* TRANSACTIONAL */
+ {
+ Initialize(reset);
+
+ return (options != null) ?
+ new List(options.Keys) : null;
+ }
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method determines if the specified option key is supported by
+ /// this class.
+ ///
+ ///
+ /// The name ("key") of the configuration option.
+ ///
+ ///
+ /// Non-zero if the specified option key is supported by this class.
+ ///
+ public static bool HaveKey(
+ string key
+ )
+ {
+ lock (syncRoot)
+ {
+ if ((key == null) || (options == null))
+ return false;
+
+ return options.ContainsKey(key);
+ }
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method attempts to query and return the current value of the
+ /// specified option key.
+ ///
+ ///
+ /// The name ("key") of the configuration option.
+ ///
+ ///
+ /// Upon success, the current value for the configuration option;
+ /// otherwise, null.
+ ///
+ ///
+ /// Non-zero for success; otherwise, zero.
+ ///
+ public static bool GetValue(
+ string key,
+ out string value
+ )
+ {
+ lock (syncRoot)
+ {
+ value = null;
+
+ if ((key == null) || (options == null))
+ return false;
+
+ if (options.TryGetValue(key, out value))
+ return true;
+
+ return false;
+ }
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method attempts to set the value of the specified option key.
+ ///
+ ///
+ /// The name ("key") of the configuration option.
+ ///
+ ///
+ /// The new value for the configuration option.
+ ///
+ ///
+ /// Non-zero for success; otherwise, zero.
+ ///
+ public static bool SetValue(
+ string key,
+ string value
+ )
+ {
+ lock (syncRoot)
+ {
+ if ((key == null) || (options == null))
+ return false;
+
+ options[key] = value;
+ return true;
+ }
+ }
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Stream Handling
+ ///
+ /// This method attempts to read an option value from the specified
+ /// stream. The stream must be readable. After this method returns,
+ /// the stream may no longer be usable.
+ ///
+ ///
+ /// The stream to read the option value from.
+ ///
+ ///
+ /// Upon success, the read value for the configuration option;
+ /// otherwise, null.
+ ///
+ ///
+ /// Non-zero for success; otherwise, zero.
+ ///
+ public static bool ReadValue(
+ Stream stream,
+ out string value
+ )
+ {
+ value = null;
+
+ if ((stream == null) || !stream.CanRead)
+ return false;
+
+ try
+ {
+ using (StreamReader streamReader = new StreamReader(stream))
+ {
+ value = streamReader.ReadToEnd();
+ return true;
+ }
+ }
+ catch (Exception)
+ {
+ // do nothing.
+ }
+
+ return false;
+ }
+
+ ///////////////////////////////////////////////////////////////////////
+
+ ///
+ /// This method attempts to write an option value to the specified
+ /// stream. The stream must be writable. After this method returns,
+ /// the stream may no longer be usable.
+ ///
+ ///
+ /// The stream to write the option value to.
+ ///
+ ///
+ /// The option value to be written. This value may be null.
+ ///
+ ///
+ /// Non-zero for success; otherwise, zero.
+ ///
+ public static bool WriteValue(
+ Stream stream,
+ string value
+ )
+ {
+ if ((stream == null) || !stream.CanWrite)
+ return false;
+
+ try
+ {
+ using (StreamWriter streamWriter = new StreamWriter(stream))
+ {
+ streamWriter.Write(value);
+ return true;
+ }
+ }
+ catch (Exception)
+ {
+ // do nothing.
+ }
+
+ return false;
+ }
+ #endregion
+ #endregion
+ }
+}
Index: SQLite.Designer/SQLitePackage.cs
==================================================================
--- SQLite.Designer/SQLitePackage.cs
+++ SQLite.Designer/SQLitePackage.cs
@@ -1,15 +1,17 @@
/********************************************************
* ADO.NET 2.0 Data Provider for SQLite Version 3.X
* Written by Robert Simpson (robert@blackcastlesoft.com)
- *
+ *
* Released to the public domain, use at your own risk!
********************************************************/
namespace SQLite.Designer
{
using System;
+ using System.Collections.Generic;
+ using System.IO;
using Microsoft.VisualStudio.Shell;
using System.Runtime.InteropServices;
using System.ComponentModel.Design;
using Microsoft.VisualStudio.Shell.Interop;
@@ -20,10 +22,22 @@
[Guid("DCBE6C8D-0E57-4099-A183-98FF74C64D9C")]
internal sealed class SQLitePackage : Package
{
public SQLitePackage()
{
+ IEnumerable keys = SQLiteOptions.GetKeys(true);
+
+ if (keys != null)
+ {
+ foreach (string key in keys)
+ {
+ if (key == null)
+ continue;
+
+ AddOptionKey(key);
+ }
+ }
}
protected override void Initialize()
{
IServiceContainer sc = (IServiceContainer)this;
@@ -31,10 +45,47 @@
ToolboxInitialized += new EventHandler(SQLitePackage_ToolboxInitialized);
ToolboxUpgraded += new EventHandler(SQLitePackage_ToolboxUpgraded);
base.Initialize();
}
+
+ protected override void OnLoadOptions(string key, Stream stream)
+ {
+ if (SQLiteOptions.HaveKey(key))
+ {
+ string value;
+
+ if (SQLiteOptions.ReadValue(stream, out value) &&
+ SQLiteOptions.IsValidValue(key, value))
+ {
+ SQLiteOptions.SetValue(key, value);
+ }
+
+ return;
+ }
+
+ base.OnLoadOptions(key, stream);
+ }
+
+ protected override void OnSaveOptions(string key, Stream stream)
+ {
+ if (SQLiteOptions.HaveKey(key))
+ {
+ string value;
+
+ if (SQLiteOptions.GetValue(key, out value) &&
+ SQLiteOptions.IsValidValue(key, value) &&
+ !SQLiteOptions.IsDefaultValue(key, value))
+ {
+ SQLiteOptions.WriteValue(stream, value);
+ }
+
+ return;
+ }
+
+ base.OnSaveOptions(key, stream);
+ }
void SQLitePackage_ToolboxUpgraded(object sender, EventArgs e)
{
IVsToolbox vstbx = GetService(typeof(SVsToolbox)) as IVsToolbox;
Index: Setup/data/SQLite.iss
==================================================================
--- Setup/data/SQLite.iss
+++ Setup/data/SQLite.iss
@@ -210,10 +210,14 @@
#if Year == "2010"
Components: Application\EF6; Source: ..\..\Externals\EntityFramework\lib\net40\EntityFramework.dll; DestDir: {app}\bin; Flags: restartreplace uninsrestartdelete
#elif Year == "2012" || Year == "2013"
Components: Application\EF6; Source: ..\..\Externals\EntityFramework\lib\net45\EntityFramework.dll; DestDir: {app}\bin; Flags: restartreplace uninsrestartdelete
#endif
+
+#if Pos("NativeOnly", AppConfiguration) == 0
+Components: Application\EF6; Tasks: gac; Source: ..\..\bin\{#Year}\{#BaseConfiguration}\bin\System.Data.SQLite.EF6.dll; DestDir: {app}\GAC; StrongAssemblyName: "System.Data.SQLite.EF6, Version={#AppVersion}, Culture=neutral, PublicKeyToken={#AppPublicKey}, ProcessorArchitecture=MSIL"; Flags: restartreplace uninsrestartdelete uninsnosharedfileprompt sharedfile gacinstall
+#endif
Components: Application\EF6; Source: ..\..\bin\{#Year}\{#BaseConfiguration}\bin\System.Data.SQLite.EF6.dll; DestDir: {app}\bin; Flags: restartreplace uninsrestartdelete
Components: Application\EF6 and Application\Symbols; Source: ..\..\bin\{#Year}\{#BaseConfiguration}\bin\System.Data.SQLite.EF6.pdb; DestDir: {app}\bin; Flags: restartreplace uninsrestartdelete
#endif
Index: Tests/data/Installer_Test_Vs2005.log
==================================================================
--- Tests/data/Installer_Test_Vs2005.log
+++ Tests/data/Installer_Test_Vs2005.log
@@ -60,8 +60,8 @@
Installer.exe: #60: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\8.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataObjectSupport"
Installer.exe: #61: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\8.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataViewSupport"
Installer.exe: #62: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\8.0", writable = False
Installer.exe: #63: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\8.0", name = "InstallDir", defaultValue =
Installer.exe: #64: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 8} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 8} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #65: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesSet = 23, keyValuesDeleted = 0
+Installer.exe: #65: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesRead = 5, keyValuesWritten = 23, keyValuesDeleted = 0
Installer.exe: #66: Installer.Main: filesCreated = 1, filesModified = 2, filesDeleted = 0
Installer.exe: #67: Installer.Main: Success.
Index: Tests/data/Installer_Test_Vs2008.log
==================================================================
--- Tests/data/Installer_Test_Vs2008.log
+++ Tests/data/Installer_Test_Vs2008.log
@@ -70,8 +70,8 @@
Installer.exe: #70: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\9.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataObjectSupport"
Installer.exe: #71: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\9.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataViewSupport"
Installer.exe: #72: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\9.0", writable = False
Installer.exe: #73: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\9.0", name = "InstallDir", defaultValue =
Installer.exe: #74: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 9.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 9.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #75: Installer.Main: subKeysCreated = 13, subKeysDeleted = 2, keyValuesSet = 24, keyValuesDeleted = 0
+Installer.exe: #75: Installer.Main: subKeysCreated = 13, subKeysDeleted = 2, keyValuesRead = 6, keyValuesWritten = 24, keyValuesDeleted = 0
Installer.exe: #76: Installer.Main: filesCreated = 1, filesModified = 2, filesDeleted = 0
Installer.exe: #77: Installer.Main: Success.
Index: Tests/data/Installer_Test_Vs2010.log
==================================================================
--- Tests/data/Installer_Test_Vs2010.log
+++ Tests/data/Installer_Test_Vs2010.log
@@ -63,8 +63,8 @@
Installer.exe: #63: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\10.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataObjectSupport"
Installer.exe: #64: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\10.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataViewSupport"
Installer.exe: #65: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\10.0", writable = False
Installer.exe: #66: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\10.0", name = "InstallDir", defaultValue =
Installer.exe: #67: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 10.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 10.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #68: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesSet = 23, keyValuesDeleted = 0
+Installer.exe: #68: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesRead = 5, keyValuesWritten = 23, keyValuesDeleted = 0
Installer.exe: #69: Installer.Main: filesCreated = 1, filesModified = 2, filesDeleted = 0
Installer.exe: #70: Installer.Main: Success.
Index: Tests/data/Installer_Test_Vs2012.log
==================================================================
--- Tests/data/Installer_Test_Vs2012.log
+++ Tests/data/Installer_Test_Vs2012.log
@@ -63,8 +63,8 @@
Installer.exe: #63: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\11.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataObjectSupport"
Installer.exe: #64: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\11.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataViewSupport"
Installer.exe: #65: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\11.0", writable = False
Installer.exe: #66: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\11.0", name = "InstallDir", defaultValue =
Installer.exe: #67: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 11.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 11.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #68: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesSet = 23, keyValuesDeleted = 0
+Installer.exe: #68: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesRead = 5, keyValuesWritten = 23, keyValuesDeleted = 0
Installer.exe: #69: Installer.Main: filesCreated = 1, filesModified = 2, filesDeleted = 0
Installer.exe: #70: Installer.Main: Success.
Index: Tests/data/Installer_Test_Vs2013.log
==================================================================
--- Tests/data/Installer_Test_Vs2013.log
+++ Tests/data/Installer_Test_Vs2013.log
@@ -63,8 +63,8 @@
Installer.exe: #63: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\12.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataObjectSupport"
Installer.exe: #64: RegistryHelper.CreateSubKey: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\12.0\DataProviders\{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}", subKeyName = "SupportedObjects\DataViewSupport"
Installer.exe: #65: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\12.0", writable = False
Installer.exe: #66: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\12.0", name = "InstallDir", defaultValue =
Installer.exe: #67: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 12.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 12.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #68: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesSet = 23, keyValuesDeleted = 0
+Installer.exe: #68: Installer.Main: subKeysCreated = 12, subKeysDeleted = 1, keyValuesRead = 5, keyValuesWritten = 23, keyValuesDeleted = 0
Installer.exe: #69: Installer.Main: filesCreated = 1, filesModified = 2, filesDeleted = 0
Installer.exe: #70: Installer.Main: Success.
Index: Tests/data/Uninstaller_Test_Vs2005.log
==================================================================
--- Tests/data/Uninstaller_Test_Vs2005.log
+++ Tests/data/Uninstaller_Test_Vs2005.log
@@ -29,8 +29,8 @@
Installer.exe: #29: RegistryHelper.DeleteSubKeyTree: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\8.0\DataProviders", subKeyName = "{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}"
Installer.exe: #30: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\8.0", writable = False
Installer.exe: #31: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\8.0", name = "InstallDir", defaultValue =
Installer.exe: #32: Installer.RemoveVsDevEnvSetup: Preparing to run Visual Studio v8.0 'setup' mode to refresh its configuration.
Installer.exe: #33: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 8} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 8} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #34: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesSet = 0, keyValuesDeleted = 1
+Installer.exe: #34: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesRead = 5, keyValuesWritten = 0, keyValuesDeleted = 1
Installer.exe: #35: Installer.Main: filesCreated = 1, filesModified = 1, filesDeleted = 0
Installer.exe: #36: Installer.Main: Success.
Index: Tests/data/Uninstaller_Test_Vs2008.log
==================================================================
--- Tests/data/Uninstaller_Test_Vs2008.log
+++ Tests/data/Uninstaller_Test_Vs2008.log
@@ -36,8 +36,8 @@
Installer.exe: #36: RegistryHelper.DeleteSubKeyTree: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\9.0\DataProviders", subKeyName = "{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}"
Installer.exe: #37: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\9.0", writable = False
Installer.exe: #38: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\9.0", name = "InstallDir", defaultValue =
Installer.exe: #39: Installer.RemoveVsDevEnvSetup: Preparing to run Visual Studio v9.0 'setup' mode to refresh its configuration.
Installer.exe: #40: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 9.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 9.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #41: Installer.Main: subKeysCreated = 0, subKeysDeleted = 6, keyValuesSet = 0, keyValuesDeleted = 1
+Installer.exe: #41: Installer.Main: subKeysCreated = 0, subKeysDeleted = 6, keyValuesRead = 6, keyValuesWritten = 0, keyValuesDeleted = 1
Installer.exe: #42: Installer.Main: filesCreated = 1, filesModified = 1, filesDeleted = 0
Installer.exe: #43: Installer.Main: Success.
Index: Tests/data/Uninstaller_Test_Vs2010.log
==================================================================
--- Tests/data/Uninstaller_Test_Vs2010.log
+++ Tests/data/Uninstaller_Test_Vs2010.log
@@ -32,8 +32,8 @@
Installer.exe: #32: RegistryHelper.DeleteSubKeyTree: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\10.0\DataProviders", subKeyName = "{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}"
Installer.exe: #33: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\10.0", writable = False
Installer.exe: #34: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\10.0", name = "InstallDir", defaultValue =
Installer.exe: #35: Installer.RemoveVsDevEnvSetup: Preparing to run Visual Studio v10.0 'setup' mode to refresh its configuration.
Installer.exe: #36: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 10.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 10.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #37: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesSet = 0, keyValuesDeleted = 1
+Installer.exe: #37: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesRead = 5, keyValuesWritten = 0, keyValuesDeleted = 1
Installer.exe: #38: Installer.Main: filesCreated = 1, filesModified = 1, filesDeleted = 0
Installer.exe: #39: Installer.Main: Success.
Index: Tests/data/Uninstaller_Test_Vs2012.log
==================================================================
--- Tests/data/Uninstaller_Test_Vs2012.log
+++ Tests/data/Uninstaller_Test_Vs2012.log
@@ -32,8 +32,8 @@
Installer.exe: #32: RegistryHelper.DeleteSubKeyTree: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\11.0\DataProviders", subKeyName = "{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}"
Installer.exe: #33: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\11.0", writable = False
Installer.exe: #34: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\11.0", name = "InstallDir", defaultValue =
Installer.exe: #35: Installer.RemoveVsDevEnvSetup: Preparing to run Visual Studio v11.0 'setup' mode to refresh its configuration.
Installer.exe: #36: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 11.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 11.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #37: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesSet = 0, keyValuesDeleted = 1
+Installer.exe: #37: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesRead = 5, keyValuesWritten = 0, keyValuesDeleted = 1
Installer.exe: #38: Installer.Main: filesCreated = 1, filesModified = 1, filesDeleted = 0
Installer.exe: #39: Installer.Main: Success.
Index: Tests/data/Uninstaller_Test_Vs2013.log
==================================================================
--- Tests/data/Uninstaller_Test_Vs2013.log
+++ Tests/data/Uninstaller_Test_Vs2013.log
@@ -32,8 +32,8 @@
Installer.exe: #32: RegistryHelper.DeleteSubKeyTree: rootKey = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\12.0\DataProviders", subKeyName = "{0ebaab6e-ca80-4b4a-8ddf-cbe6bf058c70}"
Installer.exe: #33: RegistryHelper.OpenSubKey: rootKey = "HKEY_LOCAL_MACHINE", subKeyName = "Software${wow64}\Microsoft\VisualStudio\12.0", writable = False
Installer.exe: #34: RegistryHelper.GetValue: key = "HKEY_LOCAL_MACHINE\Software${wow64}\Microsoft\VisualStudio\12.0", name = "InstallDir", defaultValue =
Installer.exe: #35: Installer.RemoveVsDevEnvSetup: Preparing to run Visual Studio v12.0 'setup' mode to refresh its configuration.
Installer.exe: #36: Installer.AddVsDevEnvSetup: fileName = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 12.0} Common7 IDE devenv.exe]]", arguments = "/setup", workingDirectory = "[file nativename [file join [expr {$is64 ? ${::env(ProgramFiles(x86))} : $::env(ProgramFiles)}] {Microsoft Visual Studio 12.0} Common7 IDE]]\", useShellExecute = False, redirectStandardOutput = True, redirectStandardError = True
-Installer.exe: #37: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesSet = 0, keyValuesDeleted = 1
+Installer.exe: #37: Installer.Main: subKeysCreated = 0, subKeysDeleted = 5, keyValuesRead = 5, keyValuesWritten = 0, keyValuesDeleted = 1
Installer.exe: #38: Installer.Main: filesCreated = 1, filesModified = 1, filesDeleted = 0
Installer.exe: #39: Installer.Main: Success.
Index: readme.htm
==================================================================
--- readme.htm
+++ readme.htm
@@ -143,11 +143,11 @@
<configuration>
<system.data>
<DbProviderFactories>
<remove invariant="System.Data.SQLite" />
- <add name="SQLite Data Provider" invariant="System.Data.SQLite" description=".Net Framework Data Provider for SQLite"
+ <add name="SQLite Data Provider" invariant="System.Data.SQLite" description=".NET Framework Data Provider for SQLite"
type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite, Version=1.0.94.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139" />
</DbProviderFactories>
</system.data>
</configuration>
Index: test/app.config
==================================================================
--- test/app.config
+++ test/app.config
@@ -1,8 +1,8 @@
-
+
Index: testlinq/2008/LINQ/App.config
==================================================================
--- testlinq/2008/LINQ/App.config
+++ testlinq/2008/LINQ/App.config
@@ -2,11 +2,11 @@
-
+
Index: testlinq/2010/EF6/App.config
==================================================================
--- testlinq/2010/EF6/App.config
+++ testlinq/2010/EF6/App.config
@@ -5,11 +5,11 @@
-
+
Index: testlinq/2010/LINQ/App.config
==================================================================
--- testlinq/2010/LINQ/App.config
+++ testlinq/2010/LINQ/App.config
@@ -2,11 +2,11 @@
-
+
Index: testlinq/2012/EF6/App.config
==================================================================
--- testlinq/2012/EF6/App.config
+++ testlinq/2012/EF6/App.config
@@ -5,11 +5,11 @@
-
+
Index: testlinq/2012/LINQ/App.config
==================================================================
--- testlinq/2012/LINQ/App.config
+++ testlinq/2012/LINQ/App.config
@@ -2,11 +2,11 @@
-
+
Index: testlinq/2013/EF6/App.config
==================================================================
--- testlinq/2013/EF6/App.config
+++ testlinq/2013/EF6/App.config
@@ -5,11 +5,11 @@
-
+
Index: testlinq/2013/LINQ/App.config
==================================================================
--- testlinq/2013/LINQ/App.config
+++ testlinq/2013/LINQ/App.config
@@ -2,11 +2,11 @@
-
+
Index: tools/install/Installer.cs
==================================================================
--- tools/install/Installer.cs
+++ tools/install/Installer.cs
@@ -95,53 +95,92 @@
#region Public Enumerations
[Flags()]
public enum InstallFlags
{
- #region Normal Flags
+ #region Normal Values
None = 0x0,
- GlobalAssemblyCache = 0x1,
- AssemblyFolders = 0x2,
- DbProviderFactory = 0x4,
- VsPackage = 0x8,
- VsPackageGlobalAssemblyCache = 0x10,
- VsDataSource = 0x20,
- VsDataProvider = 0x40,
- VsDevEnvSetup = 0x80,
+ CoreGlobalAssemblyCache = 0x1,
+ LinqGlobalAssemblyCache = 0x2,
+ Ef6GlobalAssemblyCache = 0x4,
+ AssemblyFolders = 0x8,
+ DbProviderFactory = 0x10,
+ VsPackage = 0x20,
+ VsPackageGlobalAssemblyCache = 0x40,
+ VsDataSource = 0x80,
+ VsDataProvider = 0x100,
+ VsDevEnvSetup = 0x200,
#endregion
///////////////////////////////////////////////////////////////////////
- #region Composite Flags
- Framework = GlobalAssemblyCache | AssemblyFolders |
+ #region Composite Values
+ FrameworkGlobalAssemblyCache = CoreGlobalAssemblyCache |
+ LinqGlobalAssemblyCache |
+ Ef6GlobalAssemblyCache,
+
+ ///////////////////////////////////////////////////////////////////////
+
+ Framework = FrameworkGlobalAssemblyCache | AssemblyFolders |
DbProviderFactory,
///////////////////////////////////////////////////////////////////////
Vs = VsPackage | VsPackageGlobalAssemblyCache | VsDataSource |
VsDataProvider | VsDevEnvSetup,
///////////////////////////////////////////////////////////////////////
+ AllGlobalAssemblyCache = FrameworkGlobalAssemblyCache |
+ VsPackageGlobalAssemblyCache,
+
+ ///////////////////////////////////////////////////////////////////////
+
All = Framework | Vs,
///////////////////////////////////////////////////////////////////////
- AllExceptGlobalAssemblyCache = All & ~(GlobalAssemblyCache |
- VsPackageGlobalAssemblyCache),
+ AllExceptGlobalAssemblyCache = All & ~AllGlobalAssemblyCache,
#endregion
///////////////////////////////////////////////////////////////////////
+ #region Suggested Default Values
Default = All
+ #endregion
+ }
+
+ ///////////////////////////////////////////////////////////////////////////
+
+ [Flags()]
+ public enum ProviderFlags
+ {
+ #region Normal Values
+ None = 0x0,
+ SystemEf6MustBeGlobal = 0x1,
+ DidLinqForceTrace = 0x2,
+ DidEf6ForceTrace = 0x4,
+ DidEf6ResolveTrace = 0x8,
+ ForceLinqEnabled = 0x10,
+ ForceLinqDisabled = 0x20,
+ ForceEf6Enabled = 0x40,
+ ForceEf6Disabled = 0x80,
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Suggested Default Values
+ Default = None
+ #endregion
}
///////////////////////////////////////////////////////////////////////////
[Flags()]
public enum TracePriority
{
+ #region Normal Values
None = 0x0,
Lowest = 0x1,
Lower = 0x2,
Low = 0x4,
MediumLow = 0x8,
@@ -148,11 +187,17 @@
Medium = 0x10,
MediumHigh = 0x20,
High = 0x40,
Higher = 0x80,
Highest = 0x100,
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////////
+
+ #region Suggested Default Flags
Default = Medium
+ #endregion
}
#endregion
///////////////////////////////////////////////////////////////////////////
@@ -837,10 +882,11 @@
#endregion
///////////////////////////////////////////////////////////////////
#region Public "Registry" Methods
+#if false
public object GetValue(
string keyName,
string valueName,
object defaultValue
)
@@ -878,10 +924,11 @@
CheckReadOnly();
if (!whatIf)
Registry.SetValue(keyName, valueName, value, valueKind);
}
+#endif
#endregion
///////////////////////////////////////////////////////////////////
#region Private Methods
@@ -1488,14 +1535,22 @@
get { return subKeysDeleted; }
}
///////////////////////////////////////////////////////////////////
- private static int keyValuesSet;
- public static int KeyValuesSet
+ private static int keyValuesRead;
+ public static int KeyValuesRead
{
- get { return keyValuesSet; }
+ get { return keyValuesRead; }
+ }
+
+ ///////////////////////////////////////////////////////////////////
+
+ private static int keyValuesWritten;
+ public static int KeyValuesWritten
+ {
+ get { return keyValuesWritten; }
}
///////////////////////////////////////////////////////////////////
private static int keyValuesDeleted;
@@ -1684,11 +1739,15 @@
debugCallback, traceCallback, String.Format(
"key = {0}, name = {1}, defaultValue = {2}",
ForDisplay(key), ForDisplay(name),
ForDisplay(defaultValue)), traceCategory);
- return key.GetValue(name, defaultValue);
+ object value = key.GetValue(name, defaultValue);
+
+ keyValuesRead++;
+
+ return value;
}
///////////////////////////////////////////////////////////////////
[MethodImpl(MethodImplOptions.NoInlining)]
@@ -1711,11 +1770,11 @@
traceCategory);
if (!whatIf)
key.SetValue(name, value);
- keyValuesSet++;
+ keyValuesWritten++;
}
///////////////////////////////////////////////////////////////////
[MethodImpl(MethodImplOptions.NoInlining)]
@@ -1824,19 +1883,10 @@
#endregion
///////////////////////////////////////////////////////////////////
#region Public Properties
- private string configInvariantName;
- public string ConfigInvariantName
- {
- get { return configInvariantName; }
- set { configInvariantName = value; }
- }
-
- ///////////////////////////////////////////////////////////////////
-
private string providerInvariantName;
public string ProviderInvariantName
{
get { return providerInvariantName; }
set { providerInvariantName = value; }
@@ -1985,10 +2035,11 @@
string configVersion,
string vsVersionSuffix,
string debugFormat,
string traceFormat,
InstallFlags installFlags,
+ ProviderFlags providerFlags,
TracePriority debugPriority,
TracePriority tracePriority,
bool perUser,
bool install,
bool wow64,
@@ -2026,10 +2077,11 @@
this.configVersion = configVersion;
this.vsVersionSuffix = vsVersionSuffix;
this.debugFormat = debugFormat;
this.traceFormat = traceFormat;
this.installFlags = installFlags;
+ this.providerFlags = providerFlags;
this.debugPriority = debugPriority;
this.tracePriority = tracePriority;
this.perUser = perUser;
this.install = install;
this.wow64 = wow64;
@@ -2187,11 +2239,13 @@
return null;
}
///////////////////////////////////////////////////////////////////
- private static bool IsSystemEf6AssemblyAvailable()
+ private static bool IsSystemEf6AssemblyAvailable(
+ bool trace
+ )
{
if (systemEf6Assembly != null)
return true;
try
@@ -2199,41 +2253,58 @@
systemEf6Assembly = Assembly.ReflectionOnlyLoad(
SystemEf6AssemblyName);
if (systemEf6Assembly != null)
{
- TraceOps.DebugAndTrace(TracePriority.Highest,
- debugCallback, traceCallback, String.Format(
- "Entity Framework 6 assembly was resolved to {0}.",
- ForDisplay(systemEf6Assembly.Location)),
- traceCategory);
+ if (trace)
+ {
+ TraceOps.DebugAndTrace(TracePriority.Highest,
+ debugCallback, traceCallback, String.Format(
+ "Entity Framework 6 assembly was " +
+ "resolved to {0}.", ForDisplay(
+ systemEf6Assembly.Location)),
+ traceCategory);
+ }
return true;
}
}
catch
{
// do nothing.
}
- TraceOps.DebugAndTrace(TracePriority.Highest,
- debugCallback, traceCallback,
- "Entity Framework 6 assembly was not resolved.",
- traceCategory);
+ if (trace)
+ {
+ TraceOps.DebugAndTrace(TracePriority.Highest,
+ debugCallback, traceCallback,
+ "Entity Framework 6 assembly was not resolved.",
+ traceCategory);
+ }
return false;
}
+
+ ///////////////////////////////////////////////////////////////////
+
+ private static bool IsSystemEf6AssemblyGlobal()
+ {
+ if (systemEf6Assembly == null)
+ return false;
+
+ return systemEf6Assembly.GlobalAssemblyCache;
+ }
#endregion
///////////////////////////////////////////////////////////////////
#region Public Static Methods
public static void BreakIntoDebugger()
{
Console.WriteLine(
- "Attach a debugger to process {0} and press any key to " +
- "continue.", (thisProcess != null) ?
+ "Attach a debugger to process {0} and press " +
+ "any key to continue.", (thisProcess != null) ?
thisProcess.Id.ToString() : "");
try
{
Console.ReadKey(true); /* throw */
@@ -2262,15 +2333,15 @@
return new Configuration(
thisAssembly, null, directory, coreFileName, linqFileName,
ef6FileName, designerFileName, null, null, null,
TraceOps.DebugFormat, TraceOps.TraceFormat,
- InstallFlags.Default, TracePriority.Default,
- TracePriority.Default, false, true, false, false, false,
+ InstallFlags.Default, ProviderFlags.Default,
+ TracePriority.Default, TracePriority.Default, false, true,
+ false, false, false, false, false, false, false, false,
false, false, false, false, false, false, false, false,
- false, false, false, false, false, false, true, true,
- false, false, false);
+ false, true, true, false, false, false);
}
///////////////////////////////////////////////////////////////////
[MethodImpl(MethodImplOptions.NoInlining)]
@@ -2931,10 +3002,31 @@
continue;
}
configuration.perUser = (bool)value;
}
+ else if (MatchOption(newArg, "providerFlags"))
+ {
+ object value = ParseEnum(
+ typeof(ProviderFlags), text, true);
+
+ if (value == null)
+ {
+ error = TraceOps.DebugAndTrace(
+ TracePriority.Lowest, debugCallback,
+ traceCallback, String.Format(
+ "Invalid provider flags value: {0}",
+ ForDisplay(text)), traceCategory);
+
+ if (strict)
+ return false;
+
+ continue;
+ }
+
+ configuration.providerFlags = (ProviderFlags)value;
+ }
else if (MatchOption(newArg, "registryVersion"))
{
configuration.registryVersion = text;
}
else if (MatchOption(newArg, "strict"))
@@ -3403,10 +3495,19 @@
}
#endregion
///////////////////////////////////////////////////////////////////
+ #region Private Methods
+ private string GetInvariantName()
+ {
+ return UseEf6Provider() ? Ef6InvariantName : InvariantName;
+ }
+ #endregion
+
+ ///////////////////////////////////////////////////////////////////
+
#region Public Methods
public bool HasFlags(
InstallFlags hasFlags,
bool all
)
@@ -3417,12 +3518,59 @@
return ((installFlags & hasFlags) != InstallFlags.None);
}
///////////////////////////////////////////////////////////////////
+ public bool HasFlags(
+ ProviderFlags hasFlags,
+ bool all
+ )
+ {
+ if (all)
+ return ((providerFlags & hasFlags) == hasFlags);
+ else
+ return ((providerFlags & hasFlags) != ProviderFlags.None);
+ }
+
+ ///////////////////////////////////////////////////////////////////
+
public bool IsLinqSupported()
{
+ //
+ // NOTE: Check to see if the caller has forced LINQ support to
+ // be enabled -OR- disabled, thereby bypassing the need
+ // for "automatic detection" by this method.
+ //
+ if (HasFlags(ProviderFlags.ForceLinqEnabled, true))
+ {
+ if (!HasFlags(ProviderFlags.DidLinqForceTrace, true))
+ {
+ TraceOps.DebugAndTrace(TracePriority.MediumHigh,
+ debugCallback, traceCallback,
+ "Forced to enable support for \"Linq\".",
+ traceCategory);
+
+ providerFlags |= ProviderFlags.DidLinqForceTrace;
+ }
+
+ return true;
+ }
+ else if (HasFlags(ProviderFlags.ForceLinqDisabled, true))
+ {
+ if (!HasFlags(ProviderFlags.DidLinqForceTrace, true))
+ {
+ TraceOps.DebugAndTrace(TracePriority.MediumHigh,
+ debugCallback, traceCallback,
+ "Forced to disable support for \"Linq\".",
+ traceCategory);
+
+ providerFlags |= ProviderFlags.DidLinqForceTrace;
+ }
+
+ return false;
+ }
+
//
// NOTE: Return non-zero if the System.Data.SQLite.Linq
// assembly should be processed during the install.
// If the target is Visual Studio 2005, this must
// return zero.
@@ -3432,27 +3580,109 @@
///////////////////////////////////////////////////////////////////
public bool IsEf6Supported()
{
+ //
+ // NOTE: Check to see if the caller has forced EF6 support to
+ // be enabled -OR- disabled, thereby bypassing the need
+ // for "automatic detection" by this method.
+ //
+ if (HasFlags(ProviderFlags.ForceEf6Enabled, true))
+ {
+ if (!HasFlags(ProviderFlags.DidEf6ForceTrace, true))
+ {
+ TraceOps.DebugAndTrace(TracePriority.MediumHigh,
+ debugCallback, traceCallback,
+ "Forced to enable support for \"Ef6\".",
+ traceCategory);
+
+ providerFlags |= ProviderFlags.DidEf6ForceTrace;
+ }
+
+ return true;
+ }
+ else if (HasFlags(ProviderFlags.ForceEf6Disabled, true))
+ {
+ if (!HasFlags(ProviderFlags.DidEf6ForceTrace, true))
+ {
+ TraceOps.DebugAndTrace(TracePriority.MediumHigh,
+ debugCallback, traceCallback,
+ "Forced to disable support for \"Ef6\".",
+ traceCategory);
+
+ providerFlags |= ProviderFlags.DidEf6ForceTrace;
+ }
+
+ return false;
+ }
+
//
// NOTE: Return non-zero if the System.Data.SQLite.EF6
// assembly should be processed during the install.
// If the target is Visual Studio 2005 or Visual
- // Studio 2008, this must return zero. Also, if
- // the EF6 core assembly is unavailable, this must
- // return zero.
+ // Studio 2008, this must return zero.
//
if (noNetFx40 && noNetFx45 && noNetFx451)
return false;
- return IsSystemEf6AssemblyAvailable();
+ //
+ // NOTE: Also, if the EF6 core assembly is unavailable, this
+ // must return zero.
+ //
+ if (!IsSystemEf6AssemblyAvailable(!HasFlags(
+ ProviderFlags.DidEf6ResolveTrace, true)))
+ {
+ providerFlags |= ProviderFlags.DidEf6ResolveTrace;
+ return false;
+ }
+
+ //
+ // NOTE: Finally, if the EF6 core assembly is not available
+ // globally [and this is a requirement for the current
+ // install], return zero.
+ //
+ return HasFlags(ProviderFlags.SystemEf6MustBeGlobal, true) ?
+ IsSystemEf6AssemblyGlobal() : true;
+ }
+
+ ///////////////////////////////////////////////////////////////////
+
+ private bool IsEf6AssemblyGlobal()
+ {
+ if (ef6AssemblyName == null)
+ return false;
+
+ Assembly assembly = Assembly.ReflectionOnlyLoad(
+ ef6AssemblyName.ToString());
+
+ return (assembly != null) && assembly.GlobalAssemblyCache;
+ }
+
+ ///////////////////////////////////////////////////////////////////
+
+ public bool UseEf6Provider()
+ {
+ //
+ // NOTE: We cannot use the EF6 assembly as the provider if it
+ // is not supported by this installation.
+ //
+ if (!IsEf6Supported())
+ return false;
+
+ //
+ // NOTE: For the EF6 assembly to be usable as a provider in
+ // the machine configuration file, it must be in the
+ // global assembly cache.
+ //
+ return IsEf6AssemblyGlobal();
}
///////////////////////////////////////////////////////////////////
- public AssemblyName GetCoreAssemblyName() /* REQUIRED */
+ /* REQUIRED */
+ public AssemblyName GetCoreAssemblyName() /* throw */
{
if (coreAssemblyName == null)
{
coreAssemblyName = AssemblyName.GetAssemblyName(
CoreFileName); /* throw */
@@ -3461,11 +3691,12 @@
return coreAssemblyName;
}
///////////////////////////////////////////////////////////////////
- public AssemblyName GetLinqAssemblyName() /* OPTIONAL */
+ /* OPTIONAL */
+ public AssemblyName GetLinqAssemblyName() /* throw */
{
if (IsLinqSupported() && (linqAssemblyName == null))
{
linqAssemblyName = AssemblyName.GetAssemblyName(
LinqFileName); /* throw */
@@ -3474,11 +3705,12 @@
return linqAssemblyName;
}
///////////////////////////////////////////////////////////////////
- public AssemblyName GetEf6AssemblyName() /* OPTIONAL */
+ /* OPTIONAL */
+ public AssemblyName GetEf6AssemblyName() /* throw */
{
if (IsEf6Supported() && (ef6AssemblyName == null))
{
ef6AssemblyName = AssemblyName.GetAssemblyName(
Ef6FileName); /* throw */
@@ -3487,11 +3719,12 @@
return ef6AssemblyName;
}
///////////////////////////////////////////////////////////////////
- public AssemblyName GetDesignerAssemblyName() /* REQUIRED */
+ /* REQUIRED */
+ public AssemblyName GetDesignerAssemblyName() /* throw */
{
if (designerAssemblyName == null)
{
designerAssemblyName = AssemblyName.GetAssemblyName(
DesignerFileName); /* throw */
@@ -3500,35 +3733,36 @@
return designerAssemblyName;
}
///////////////////////////////////////////////////////////////////
+ /* REQUIRED */
+ public AssemblyName GetProviderAssemblyName() /* throw */
+ {
+ return UseEf6Provider() ?
+ GetEf6AssemblyName() : GetCoreAssemblyName();
+ }
+
+ ///////////////////////////////////////////////////////////////////
+
public string GetConfigInvariantName()
{
- return InvariantName;
+ return GetInvariantName();
}
///////////////////////////////////////////////////////////////////
public string GetProviderInvariantName()
{
- return IsEf6Supported() ? Ef6InvariantName : InvariantName;
+ return GetInvariantName();
}
///////////////////////////////////////////////////////////////////
public string GetFactoryTypeName()
{
- return IsEf6Supported() ? Ef6FactoryTypeName : FactoryTypeName;
- }
-
- ///////////////////////////////////////////////////////////////////
-
- public AssemblyName GetProviderAssemblyName()
- {
- return IsEf6Supported() ?
- GetEf6AssemblyName() : GetCoreAssemblyName(); /* throw */
+ return UseEf6Provider() ? Ef6FactoryTypeName : FactoryTypeName;
}
///////////////////////////////////////////////////////////////////
public void Dump(
@@ -3586,10 +3820,14 @@
traceCategory);
traceCallback(String.Format(NameAndValueFormat,
"InstallFlags", ForDisplay(installFlags)),
traceCategory);
+
+ traceCallback(String.Format(NameAndValueFormat,
+ "ProviderFlags", ForDisplay(providerFlags)),
+ traceCategory);
traceCallback(String.Format(NameAndValueFormat,
"DebugPriority", ForDisplay(debugPriority)),
traceCategory);
@@ -3708,37 +3946,104 @@
traceCategory);
}
///////////////////////////////////////////////////////////
+ traceCallback(String.Format(NameAndValueFormat,
+ "IsSystemEf6AssemblyAvailable", ForDisplay(
+ IsSystemEf6AssemblyAvailable(false))),
+ traceCategory);
+
+ traceCallback(String.Format(NameAndValueFormat,
+ "IsSystemEf6AssemblyGlobal", ForDisplay(
+ IsSystemEf6AssemblyGlobal())),
+ traceCategory);
+
+ ///////////////////////////////////////////////////////////
+
traceCallback(String.Format(NameAndValueFormat,
"IsLinqSupported", ForDisplay(IsLinqSupported())),
traceCategory);
traceCallback(String.Format(NameAndValueFormat,
"IsEf6Supported", ForDisplay(IsEf6Supported())),
traceCategory);
+
+ traceCallback(String.Format(NameAndValueFormat,
+ "IsEf6AssemblyGlobal", ForDisplay(
+ IsEf6AssemblyGlobal())),
+ traceCategory);
+
+ traceCallback(String.Format(NameAndValueFormat,
+ "UseEf6Provider", ForDisplay(UseEf6Provider())),
+ traceCategory);
+
+ ///////////////////////////////////////////////////////////
+
+ try
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetCoreAssemblyName", ForDisplay(
+ GetCoreAssemblyName())), traceCategory);
+ }
+ catch (Exception e)
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetCoreAssemblyName", ForDisplay(e)),
+ traceCategory);
+ }
+
+ ///////////////////////////////////////////////////////////
+
+ try
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetLinqAssemblyName", ForDisplay(
+ GetLinqAssemblyName())), traceCategory);
+ }
+ catch (Exception e)
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetLinqAssemblyName", ForDisplay(e)),
+ traceCategory);
+ }
+
+ ///////////////////////////////////////////////////////////
+
+ try
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetEf6AssemblyName", ForDisplay(
+ GetEf6AssemblyName())), traceCategory);
+ }
+ catch (Exception e)
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetEf6AssemblyName", ForDisplay(e)),
+ traceCategory);
+ }
+
+ ///////////////////////////////////////////////////////////
+
+ try
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetDesignerAssemblyName", ForDisplay(
+ GetDesignerAssemblyName())), traceCategory);
+ }
+ catch (Exception e)
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetDesignerAssemblyName", ForDisplay(e)),
+ traceCategory);
+ }
///////////////////////////////////////////////////////////
traceCallback(String.Format(NameAndValueFormat,
- "GetCoreAssemblyName", ForDisplay(
- GetCoreAssemblyName())), traceCategory);
-
- traceCallback(String.Format(NameAndValueFormat,
- "GetLinqAssemblyName", ForDisplay(
- GetLinqAssemblyName())), traceCategory);
-
- traceCallback(String.Format(NameAndValueFormat,
- "GetEf6AssemblyName", ForDisplay(
- GetEf6AssemblyName())), traceCategory);
-
- traceCallback(String.Format(NameAndValueFormat,
- "GetDesignerAssemblyName", ForDisplay(
- GetDesignerAssemblyName())), traceCategory);
-
- ///////////////////////////////////////////////////////////
+ "GetInvariantName", ForDisplay(GetInvariantName())),
+ traceCategory);
traceCallback(String.Format(NameAndValueFormat,
"GetConfigInvariantName", ForDisplay(
GetConfigInvariantName())), traceCategory);
@@ -3748,13 +4053,24 @@
traceCallback(String.Format(NameAndValueFormat,
"GetFactoryTypeName", ForDisplay(
GetFactoryTypeName())), traceCategory);
- traceCallback(String.Format(NameAndValueFormat,
- "GetProviderAssemblyName", ForDisplay(
- GetProviderAssemblyName())), traceCategory);
+ ///////////////////////////////////////////////////////////
+
+ try
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetProviderAssemblyName", ForDisplay(
+ GetProviderAssemblyName())), traceCategory);
+ }
+ catch (Exception e)
+ {
+ traceCallback(String.Format(NameAndValueFormat,
+ "GetProviderAssemblyName", ForDisplay(e)),
+ traceCategory);
+ }
}
}
#endregion
///////////////////////////////////////////////////////////////////
@@ -3872,10 +4188,19 @@
public InstallFlags InstallFlags
{
get { return installFlags; }
set { installFlags = value; }
}
+
+ ///////////////////////////////////////////////////////////////////
+
+ private ProviderFlags providerFlags;
+ public ProviderFlags ProviderFlags
+ {
+ get { return providerFlags; }
+ set { providerFlags = value; }
+ }
///////////////////////////////////////////////////////////////////
private TracePriority debugPriority;
public TracePriority DebugPriority
@@ -4491,13 +4816,19 @@
result = value.ToString();
if (result.Length == 0)
return "";
- result = String.Format(
- type.IsSubclassOf(typeof(ValueType)) ? "{0}" : "\"{0}\"",
- result);
+ if (type.IsSubclassOf(typeof(Exception)))
+ {
+ result = String.Format(
+ "{0}{1}{0}", Environment.NewLine, result);
+ }
+ else if (!type.IsSubclassOf(typeof(ValueType)))
+ {
+ result = String.Format("\"{0}\"", result);
+ }
}
return result;
}
#endregion
@@ -6196,11 +6527,10 @@
///////////////////////////////////////////////////////////////////////
#region Visual Studio Package Handling
private static void InitializeVsPackage(
- string configInvariantName,
string providerInvariantName,
string factoryTypeName,
AssemblyName providerAssemblyName,
AssemblyName designerAssemblyName,
bool globalAssemblyCache,
@@ -6209,11 +6539,10 @@
{
if (package == null)
{
package = new Package();
- package.ConfigInvariantName = configInvariantName;
package.ProviderInvariantName = providerInvariantName;
package.FactoryTypeName = factoryTypeName;
package.ProviderAssemblyName = providerAssemblyName;
package.DesignerAssemblyName = designerAssemblyName;
package.GlobalAssemblyCache = globalAssemblyCache;
@@ -6757,11 +7086,11 @@
#endregion
#endregion
///////////////////////////////////////////////////////////////////////
- #region Application Entry Point
+ #region Installer Entry Point
[MethodImpl(MethodImplOptions.NoInlining)]
private static int Main(
string[] args
)
{
@@ -6800,21 +7129,30 @@
}
#endregion
///////////////////////////////////////////////////////////////
+ //
+ // NOTE: Setup the "mock" registry per the "what-if" mode.
+ // Since all registry access performed by this installer
+ // uses this "mock" registry, it is impossible for any
+ // actual system changes to occur unless "what-if" mode
+ // is disabled. Furthermore, protections are in place
+ // to prevent direct access to the wrapped registry keys
+ // when "safe" mode is enabled.
+ //
using (MockRegistry registry = new MockRegistry(
configuration.WhatIf, false, false))
{
- #region Core Assembly Name Check
+ #region Assembly Name Checks
//
// NOTE: Query all the assembly names first, before making
- // any changes to the system, because this will throw
- // an exception if any of the file names do not point
- // to a valid managed assembly. The values of these
- // local variables are never used after this point;
- // however, do not remove them.
+ // any changes to the system, because these calls
+ // will throw exceptions if any of the file names do
+ // not point to a valid managed assembly. The values
+ // of these local variables are never used after this
+ // point; however, do not remove them.
//
AssemblyName coreAssemblyName =
configuration.GetCoreAssemblyName(); /* NOT USED */
AssemblyName linqAssemblyName =
@@ -6860,17 +7198,16 @@
VsList vsList = null;
///////////////////////////////////////////////////////////
InitializeVsPackage(
- configuration.GetConfigInvariantName(),
configuration.GetProviderInvariantName(),
configuration.GetFactoryTypeName(),
configuration.GetProviderAssemblyName(),
configuration.GetDesignerAssemblyName(),
configuration.HasFlags(
- InstallFlags.GlobalAssemblyCache, true) &&
+ InstallFlags.AllGlobalAssemblyCache, true) &&
configuration.HasFlags(
InstallFlags.VsPackageGlobalAssemblyCache, true),
ref package);
///////////////////////////////////////////////////////////
@@ -6896,61 +7233,91 @@
///////////////////////////////////////////////////////////
#region .NET GAC Install/Remove
if (configuration.HasFlags(
- InstallFlags.GlobalAssemblyCache, true))
+ InstallFlags.AllGlobalAssemblyCache, false))
{
Publish publish = null;
if (!configuration.WhatIf)
publish = new Publish();
if (configuration.Install)
{
- if (!configuration.WhatIf)
- /* throw */
- publish.GacInstall(configuration.CoreFileName);
-
- TraceOps.DebugAndTrace(TracePriority.Highest,
- debugCallback, traceCallback, String.Format(
- "GacInstall: assemblyPath = {0}",
- ForDisplay(configuration.CoreFileName)),
- traceCategory);
-
- if (configuration.IsLinqSupported())
- {
- if (!configuration.WhatIf)
- /* throw */
- publish.GacInstall(configuration.LinqFileName);
+ if (configuration.HasFlags(
+ InstallFlags.CoreGlobalAssemblyCache,
+ true))
+ {
+ if (!configuration.WhatIf)
+ {
+ /* throw */
+ publish.GacInstall(
+ configuration.CoreFileName);
+ }
+
+ TraceOps.DebugAndTrace(TracePriority.Highest,
+ debugCallback, traceCallback, String.Format(
+ "GacInstall: assemblyPath = {0}",
+ ForDisplay(configuration.CoreFileName)),
+ traceCategory);
+ }
+
+ ///////////////////////////////////////////////////
+
+ if (configuration.HasFlags(
+ InstallFlags.LinqGlobalAssemblyCache,
+ true) &&
+ configuration.IsLinqSupported())
+ {
+ if (!configuration.WhatIf)
+ {
+ /* throw */
+ publish.GacInstall(
+ configuration.LinqFileName);
+ }
TraceOps.DebugAndTrace(TracePriority.Highest,
debugCallback, traceCallback, String.Format(
"GacInstall: assemblyPath = {0}",
ForDisplay(configuration.LinqFileName)),
traceCategory);
}
- if (configuration.IsEf6Supported())
+ ///////////////////////////////////////////////////
+
+ if (configuration.HasFlags(
+ InstallFlags.Ef6GlobalAssemblyCache,
+ true) &&
+ configuration.IsEf6Supported())
{
if (!configuration.WhatIf)
+ {
/* throw */
- publish.GacInstall(configuration.Ef6FileName);
+ publish.GacInstall(
+ configuration.Ef6FileName);
+ }
TraceOps.DebugAndTrace(TracePriority.Highest,
debugCallback, traceCallback, String.Format(
"GacInstall: assemblyPath = {0}",
ForDisplay(configuration.Ef6FileName)),
traceCategory);
}
+ ///////////////////////////////////////////////////
+
if (configuration.HasFlags(
- InstallFlags.VsPackageGlobalAssemblyCache, true))
+ InstallFlags.VsPackageGlobalAssemblyCache,
+ true))
{
if (!configuration.WhatIf)
+ {
/* throw */
- publish.GacInstall(configuration.DesignerFileName);
+ publish.GacInstall(
+ configuration.DesignerFileName);
+ }
TraceOps.DebugAndTrace(TracePriority.Highest,
debugCallback, traceCallback, String.Format(
"GacInstall: assemblyPath = {0}",
ForDisplay(configuration.DesignerFileName)),
@@ -6958,58 +7325,88 @@
}
}
else
{
if (configuration.HasFlags(
- InstallFlags.VsPackageGlobalAssemblyCache, true))
+ InstallFlags.VsPackageGlobalAssemblyCache,
+ true))
{
if (!configuration.WhatIf)
+ {
/* throw */
- publish.GacRemove(configuration.DesignerFileName);
+ publish.GacRemove(
+ configuration.DesignerFileName);
+ }
TraceOps.DebugAndTrace(TracePriority.Highest,
debugCallback, traceCallback, String.Format(
"GacRemove: assemblyPath = {0}",
ForDisplay(configuration.DesignerFileName)),
traceCategory);
}
- if (configuration.IsEf6Supported())
+ ///////////////////////////////////////////////////
+
+ if (configuration.HasFlags(
+ InstallFlags.Ef6GlobalAssemblyCache,
+ true) &&
+ configuration.IsEf6Supported())
{
if (!configuration.WhatIf)
+ {
/* throw */
- publish.GacRemove(configuration.Ef6FileName);
+ publish.GacRemove(
+ configuration.Ef6FileName);
+ }
TraceOps.DebugAndTrace(TracePriority.Highest,
debugCallback, traceCallback, String.Format(
"GacRemove: assemblyPath = {0}",
ForDisplay(configuration.Ef6FileName)),
traceCategory);
}
- if (configuration.IsLinqSupported())
+ ///////////////////////////////////////////////////
+
+ if (configuration.HasFlags(
+ InstallFlags.LinqGlobalAssemblyCache,
+ true) &&
+ configuration.IsLinqSupported())
{
if (!configuration.WhatIf)
+ {
/* throw */
- publish.GacRemove(configuration.LinqFileName);
+ publish.GacRemove(
+ configuration.LinqFileName);
+ }
TraceOps.DebugAndTrace(TracePriority.Highest,
debugCallback, traceCallback, String.Format(
"GacRemove: assemblyPath = {0}",
ForDisplay(configuration.LinqFileName)),
traceCategory);
}
- if (!configuration.WhatIf)
- /* throw */
- publish.GacRemove(configuration.CoreFileName);
-
- TraceOps.DebugAndTrace(TracePriority.Highest,
- debugCallback, traceCallback, String.Format(
- "GacRemove: assemblyPath = {0}",
- ForDisplay(configuration.CoreFileName)),
- traceCategory);
+ ///////////////////////////////////////////////////
+
+ if (configuration.HasFlags(
+ InstallFlags.CoreGlobalAssemblyCache,
+ true))
+ {
+ if (!configuration.WhatIf)
+ {
+ /* throw */
+ publish.GacRemove(
+ configuration.CoreFileName);
+ }
+
+ TraceOps.DebugAndTrace(TracePriority.Highest,
+ debugCallback, traceCallback, String.Format(
+ "GacRemove: assemblyPath = {0}",
+ ForDisplay(configuration.CoreFileName)),
+ traceCategory);
+ }
}
}
#endregion
///////////////////////////////////////////////////////////
@@ -7050,12 +7447,13 @@
bool saved = false;
if (!ForEachFrameworkConfig(registry,
frameworkList, ProcessDbProviderFactory,
configuration.ConfigVersion,
- package.ConfigInvariantName, ProviderName,
- Description, package.FactoryTypeName,
+ configuration.GetConfigInvariantName(),
+ ProviderName, Description,
+ package.FactoryTypeName,
package.ProviderAssemblyName, directoryData,
configuration.PerUser,
NetFxIs32BitOnly || configuration.Wow64,
configuration.ThrowOnMissing,
configuration.WhatIf, configuration.Verbose,
@@ -7195,14 +7593,16 @@
#region Log Summary
TraceOps.DebugAndTrace(TracePriority.MediumHigh,
debugCallback, traceCallback, String.Format(
"subKeysCreated = {0}, subKeysDeleted = {1}, " +
- "keyValuesSet = {2}, keyValuesDeleted = {3}",
+ "keyValuesRead = {2}, keyValuesWritten = {3}, " +
+ "keyValuesDeleted = {4}",
ForDisplay(RegistryHelper.SubKeysCreated),
ForDisplay(RegistryHelper.SubKeysDeleted),
- ForDisplay(RegistryHelper.KeyValuesSet),
+ ForDisplay(RegistryHelper.KeyValuesRead),
+ ForDisplay(RegistryHelper.KeyValuesWritten),
ForDisplay(RegistryHelper.KeyValuesDeleted)),
traceCategory);
TraceOps.DebugAndTrace(TracePriority.MediumHigh,
debugCallback, traceCallback, String.Format(