You've already forked linux-packaging-mono
Imported Upstream version 4.3.2.467
Former-commit-id: 9c2cb47f45fa221e661ab616387c9cda183f283d
This commit is contained in:
@@ -2,9 +2,9 @@
|
||||
// <copyright file="AcceptRejectRule.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="false" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">amirhmy</owner>
|
||||
// <owner current="true" primary="false">markash</owner>
|
||||
// <owner current="false" primary="false">jasonzhu</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
|
@@ -2,9 +2,9 @@
|
||||
// <copyright file="AggregateType.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="false" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">amirhmy</owner>
|
||||
// <owner current="true" primary="false">markash</owner>
|
||||
// <owner current="false" primary="false">jasonzhu</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="CatalogLocation.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">markash</owner>
|
||||
// <owner current="true" primary="false">laled</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data.Common {
|
||||
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="CommandBehavior.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">markash</owner>
|
||||
// <owner current="true" primary="false">laled</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
@@ -14,7 +14,7 @@ namespace System.Data {
|
||||
SingleResult = 1, // with data, force single result, may affect database
|
||||
SchemaOnly = 2, // column info, no data, no effect on database
|
||||
KeyInfo = 4, // column info + primary key information (if available)
|
||||
//
|
||||
// UNDONE: SingleRow = 8 | SingleResult,
|
||||
SingleRow = 8, // data, hint single row and single result, may affect database - doesn't apply to child(chapter) results
|
||||
SequentialAccess = 0x10,
|
||||
CloseConnection = 0x20,
|
||||
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="CommandType.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">markash</owner>
|
||||
// <owner current="true" primary="false">laled</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="AdapterSwitches.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">markash</owner>
|
||||
// <owner current="true" primary="false">laled</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
#if DEBUG
|
||||
|
@@ -1 +1 @@
|
||||
f8880b5d09ba0af05986f7f82be2593ae8caf155
|
||||
8103f0fce6e26a6c2e6ce8987157ed229da0a861
|
@@ -109,6 +109,7 @@ namespace System.Data.Common {
|
||||
private readonly Hashtable _parsetable;
|
||||
internal readonly NameValuePair KeyChain;
|
||||
internal readonly bool HasPasswordKeyword;
|
||||
internal readonly bool HasUserIdKeyword;
|
||||
|
||||
// differences between OleDb and Odbc
|
||||
// ODBC:
|
||||
@@ -144,12 +145,14 @@ namespace System.Data.Common {
|
||||
if (0 < _usersConnectionString.Length) {
|
||||
KeyChain = ParseInternal(_parsetable, _usersConnectionString, true, synonyms, UseOdbcRules);
|
||||
HasPasswordKeyword = (_parsetable.ContainsKey(KEY.Password) || _parsetable.ContainsKey(SYNONYM.Pwd));
|
||||
HasUserIdKeyword = (_parsetable.ContainsKey(KEY.User_ID) || _parsetable.ContainsKey(SYNONYM.UID));
|
||||
}
|
||||
}
|
||||
|
||||
protected DbConnectionOptions(DbConnectionOptions connectionOptions) { // Clone used by SqlConnectionString
|
||||
_usersConnectionString = connectionOptions._usersConnectionString;
|
||||
HasPasswordKeyword = connectionOptions.HasPasswordKeyword;
|
||||
HasUserIdKeyword = connectionOptions.HasUserIdKeyword;
|
||||
UseOdbcRules = connectionOptions.UseOdbcRules;
|
||||
_parsetable = connectionOptions._parsetable;
|
||||
KeyChain = connectionOptions.KeyChain;
|
||||
|
@@ -128,7 +128,7 @@ namespace System.Data.Common {
|
||||
foreach(string keyword in Keys) {
|
||||
object value;
|
||||
if (ShouldSerialize(keyword) && TryGetValue(keyword, out value)) {
|
||||
string keyvalue = (null != value) ? Convert.ToString(value, CultureInfo.InvariantCulture) : (string)null;
|
||||
string keyvalue = ConvertValueToString(value);
|
||||
AppendKeyValuePair(builder, keyword, keyvalue, UseOdbcRules);
|
||||
}
|
||||
}
|
||||
@@ -213,6 +213,10 @@ namespace System.Data.Common {
|
||||
}
|
||||
}
|
||||
|
||||
internal virtual string ConvertValueToString(object value) {
|
||||
return (value == null) ? (string)null : Convert.ToString(value, CultureInfo.InvariantCulture);
|
||||
}
|
||||
|
||||
void System.Collections.IDictionary.Add(object keyword, object value) {
|
||||
Add(ObjectToString(keyword), value);
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -2,8 +2,8 @@
|
||||
// <copyright file="Groupbybehavior.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">rickfe</owner>
|
||||
// <owner current="true" primary="false">stevesta</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data.Common {
|
||||
|
@@ -2,9 +2,9 @@
|
||||
// <copyright file="NativeMethods.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">markash</owner>
|
||||
// <owner current="true" primary="false">blained</owner>
|
||||
// <owner current="true" primary="false">mithomas</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
using System;
|
||||
|
76
external/referencesource/System.Data/System/Data/Common/SqlEventSource.cs
vendored
Normal file
76
external/referencesource/System.Data/System/Data/Common/SqlEventSource.cs
vendored
Normal file
@@ -0,0 +1,76 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <copyright file="SqlEventSource.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">mihailsm</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data
|
||||
{
|
||||
using System;
|
||||
using System.Diagnostics.Tracing;
|
||||
|
||||
[EventSource(Name = SqlEventSource.EventSourceName)]
|
||||
internal sealed class SqlEventSource : EventSource
|
||||
{
|
||||
internal const string EventSourceName = "Microsoft-AdoNet-SystemData";
|
||||
|
||||
/// <summary>
|
||||
/// Defines EventId for BeginExecute (Reader, Scalar, NonQuery, XmlReader).
|
||||
/// </summary>
|
||||
private const int BeginExecuteEventId = 1;
|
||||
|
||||
/// <summary>
|
||||
/// Defines EventId for EndExecute (Reader, Scalar, NonQuery, XmlReader).
|
||||
/// </summary>
|
||||
private const int EndExecuteEventId = 2;
|
||||
|
||||
// Defines the singleton instance for the Resources ETW provider
|
||||
internal static readonly SqlEventSource Log = new SqlEventSource();
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Keyword definitions. These represent logical groups of events that can be turned on and off independently
|
||||
/// Often each task has a keyword, but where tasks are determined by subsystem, keywords are determined by
|
||||
/// usefulness to end users to filter. Generally users don't mind extra events if they are not high volume
|
||||
/// so grouping low volume events together in a single keywords is OK (users can post-filter by task if desired)
|
||||
/// <remarks>The visibility of the enum has to be public, otherwise there will be an ArgumentException on calling related WriteEvent method.</remarks>
|
||||
/// </summary>
|
||||
public static class Keywords
|
||||
{
|
||||
public const EventKeywords SqlClient = (EventKeywords)0x0001; // This is bit 0
|
||||
}
|
||||
|
||||
public static class Tasks // this name is important for EventSource
|
||||
{
|
||||
/// <summary>Task that tracks sql command execute.</summary>
|
||||
public const EventTask ExecuteCommand = (EventTask)1;
|
||||
}
|
||||
|
||||
private SqlEventSource()
|
||||
{
|
||||
}
|
||||
|
||||
// unfortunately these are not marked as Start/Stop opcodes. The reason is that we dont want them to participate in
|
||||
// the EventSource activity IDs (because they currently don't use tasks and this simply confuses the logic) and
|
||||
// because of versioning requirements we don't have ActivityOptions capability (because mscorlib and System.Data version
|
||||
// at different rates) Sigh...
|
||||
[Event(SqlEventSource.BeginExecuteEventId, Keywords = Keywords.SqlClient)]
|
||||
public void BeginExecute(int objectId, string dataSource, string database, string commandText)
|
||||
{
|
||||
// we do not use unsafe code for better performance optization here because optimized helpers make the code unsafe where that would not be the case otherwise.
|
||||
// This introduces the question of partial trust, which is complex in the SQL case (there are a lot of scenarios and SQL has special security support).
|
||||
WriteEvent(SqlEventSource.BeginExecuteEventId, objectId, dataSource, database, commandText);
|
||||
}
|
||||
|
||||
// unfortunately these are not marked as Start/Stop opcodes. The reason is that we dont want them to participate in
|
||||
// the EventSource activity IDs (because they currently don't use tasks and this simply confuses the logic) and
|
||||
// because of versioning requirements we don't have ActivityOptions capability (because mscorlib and System.Data version
|
||||
// at different rates) Sigh...
|
||||
[Event(SqlEventSource.EndExecuteEventId, Keywords = Keywords.SqlClient)]
|
||||
public void EndExecute(int objectId, int compositeState, int sqlExceptionNumber)
|
||||
{
|
||||
WriteEvent(SqlEventSource.EndExecuteEventId, objectId, compositeState, sqlExceptionNumber);
|
||||
}
|
||||
}
|
||||
}
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="supportedJoinOperators.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">rickfe</owner>
|
||||
// <owner current="true" primary="false">stevesta</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data.Common {
|
||||
|
@@ -18,7 +18,7 @@ namespace System.Data.Common {
|
||||
public class DbEnumerator : IEnumerator {
|
||||
|
||||
internal IDataReader _reader;
|
||||
internal IDataRecord _current;
|
||||
internal DbDataRecord _current;
|
||||
internal SchemaInfo[] _schemaInfo; // shared schema info among all the data records
|
||||
internal PropertyDescriptorCollection _descriptors; // cached property descriptors
|
||||
private FieldNameLookup _fieldNameLookup; // MDAC 69015
|
||||
@@ -39,30 +39,21 @@ namespace System.Data.Common {
|
||||
_reader = reader;
|
||||
this.closeReader = closeReader;
|
||||
}
|
||||
|
||||
public DbEnumerator(DbDataReader reader)
|
||||
: this((IDataReader)reader) {
|
||||
}
|
||||
|
||||
public DbEnumerator(DbDataReader reader, bool closeReader)
|
||||
: this((IDataReader)reader, closeReader) {
|
||||
}
|
||||
|
||||
public object Current {
|
||||
get {
|
||||
return _current;
|
||||
}
|
||||
}
|
||||
|
||||
/*public IDataRecord Current {
|
||||
get {
|
||||
return _current;
|
||||
}
|
||||
}*/
|
||||
|
||||
/*
|
||||
virtual internal IDataRecord NewRecord(SchemaInfo[] si, object[] values, PropertyDescriptorCollection descriptors) {
|
||||
return new DbDataRecord(si, values, descriptors);
|
||||
}
|
||||
|
||||
virtual internal void GetValues(object[] values) {
|
||||
_reader.GetValues(values);
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
public bool MoveNext() {
|
||||
|
||||
if (null == _schemaInfo) {
|
||||
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="identifiercase.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">rickfe</owner>
|
||||
// <owner current="true" primary="false">stevesta</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data.Common {
|
||||
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="ConflictOptions.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">markash</owner>
|
||||
// <owner current="true" primary="false">laled</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
|
@@ -2,8 +2,8 @@
|
||||
// <copyright file="ConnectionState.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">markash</owner>
|
||||
// <owner current="true" primary="false">laled</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
|
@@ -2,9 +2,9 @@
|
||||
// <copyright file="DataColumnChangeEventHandler.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="false" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">amirhmy</owner>
|
||||
// <owner current="true" primary="false">markash</owner>
|
||||
// <owner current="false" primary="false">jasonzhu</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
|
@@ -2,9 +2,9 @@
|
||||
// <copyright file="DataRowAction.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// <owner current="true" primary="true">[....]</owner>
|
||||
// <owner current="true" primary="false">[....]</owner>
|
||||
// <owner current="false" primary="false">[....]</owner>
|
||||
// <owner current="true" primary="true">amirhmy</owner>
|
||||
// <owner current="true" primary="false">markash</owner>
|
||||
// <owner current="false" primary="false">jasonzhu</owner>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace System.Data {
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user