-
Notifications
You must be signed in to change notification settings - Fork 825
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reorganized Entity Framework support
- Reorganized the code into three projects/packages: 1) The Npgsql "core", fully functional ADO.NET and no EF 2) Npgsql.EntityFramework, an add-on for users of EF6 and above 3) Npgsql.EntityFrameworkLegacy, an add-on for users of EF5 and below - All EF-related code has been split off from Npgsql and into the Npgsql.EntityFramework directory - The same EF code is built via two projects: Npgsql.EntityFramework (defining ENTITIES6 for the new EF6), and Npgsql.EntityFrameworkLegacy (not defining it for pre-EF6). Still to be done: - Npgsql.NpgsqlFactory doesn't yet do the reflection work to return the pre-EF6 NpgsqlServices - Only the 2013 sln is up to date - nuspecs
- Loading branch information
Showing
264 changed files
with
395 additions
and
143 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,5 +7,5 @@ | |
/*.nupkg | ||
[Bb]in/ | ||
[Bb]uild/ | ||
/src/[Oo]bj/ | ||
/tests/[Oo]bj/ | ||
[Oo]bj/ | ||
[Oo]bj/ |
17 changes: 5 additions & 12 deletions
17
src/Npgsql/AssemblyInfo.cs → CommonAssemblyInfo.cs
100644 → 100755
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,22 @@ | ||
using System; | ||
using System; | ||
using System.Runtime.CompilerServices; | ||
using System.Security; | ||
using System.Reflection; | ||
using System.Resources; | ||
|
||
// ------------------------------------------------------------------------------ | ||
// <autogenerated> | ||
// This code was generated by a tool. | ||
// Mono Runtime Version: 2.0.50727.1433 | ||
// | ||
// Changes to this file may cause incorrect behavior and will be lost if | ||
// the code is regenerated. | ||
// </autogenerated> | ||
// ------------------------------------------------------------------------------ | ||
// Contains assembly attributes shared by all Npgsql projects | ||
|
||
[assembly: CLSCompliantAttribute(true)] | ||
[assembly: AllowPartiallyTrustedCallersAttribute()] | ||
#if NET40 | ||
[assembly: System.Security.SecurityRules(System.Security.SecurityRuleSet.Level1)] | ||
#endif | ||
[assembly: AssemblyTitleAttribute("Npgsql - .Net Data Provider for PostgreSQL")] | ||
[assembly: AssemblyDescriptionAttribute(".Net Data Provider for PostgreSQL")] | ||
[assembly: AssemblyCompanyAttribute("Npgsql Development Team")] | ||
[assembly: AssemblyProductAttribute("Npgsql")] | ||
[assembly: AssemblyCopyrightAttribute("Copyright © 2002 - 2013 Npgsql Development Team")] | ||
[assembly: AssemblyTrademarkAttribute("")] | ||
[assembly: AssemblyVersionAttribute("2.1.0")] | ||
[assembly: AssemblyFileVersionAttribute("2.1.0")] | ||
[assembly: AssemblyInformationalVersionAttribute("2.1.0-beta1")] | ||
[assembly: NeutralResourcesLanguageAttribute("en", UltimateResourceFallbackLocation.MainAssembly)] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProductVersion>9.0.30729</ProductVersion> | ||
<SchemaVersion>2.0</SchemaVersion> | ||
<ProjectGuid>{3EC85CBA-5B79-11E3-8104-0022198AB089}</ProjectGuid> | ||
<OutputType>Library</OutputType> | ||
<AppDesignerFolder>Properties</AppDesignerFolder> | ||
<AssemblyName>Npgsql.EntityFramework</AssemblyName> | ||
<FileAlignment>512</FileAlignment> | ||
<SignAssembly>true</SignAssembly> | ||
<AssemblyOriginatorKeyFile>..\Npgsql.snk</AssemblyOriginatorKeyFile> | ||
<FileUpgradeFlags> | ||
</FileUpgradeFlags> | ||
<OldToolsVersion>3.5</OldToolsVersion> | ||
<UpgradeBackupLocation /> | ||
<TargetFrameworkProfile /> | ||
<PublishUrl>publish\</PublishUrl> | ||
<Install>true</Install> | ||
<InstallFrom>Disk</InstallFrom> | ||
<UpdateEnabled>false</UpdateEnabled> | ||
<UpdateMode>Foreground</UpdateMode> | ||
<UpdateInterval>7</UpdateInterval> | ||
<UpdateIntervalUnits>Days</UpdateIntervalUnits> | ||
<UpdatePeriodically>false</UpdatePeriodically> | ||
<UpdateRequired>false</UpdateRequired> | ||
<MapFileExtensions>true</MapFileExtensions> | ||
<ApplicationRevision>0</ApplicationRevision> | ||
<ApplicationVersion>1.0.0.%2a</ApplicationVersion> | ||
<IsWebBootstrapper>false</IsWebBootstrapper> | ||
<UseApplicationTrust>false</UseApplicationTrust> | ||
<BootstrapperEnabled>true</BootstrapperEnabled> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug-net45|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Debug-net45\</OutputPath> | ||
<DefineConstants>TRACE;DEBUG;WINDOWS;UNMANAGED;NET35;NET40;NET45;ENTITIES6</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Debug-net45\Npgsql.EntityFramework.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release-net45|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Release-net45\</OutputPath> | ||
<DefineConstants>TRACE;WINDOWS;UNMANAGED;NET35;NET40;NET45;ENTITIES6</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Release-net45\Npgsql.EntityFramework.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug-net40|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Debug-net40\</OutputPath> | ||
<DefineConstants>TRACE;DEBUG;WINDOWS;UNMANAGED;NET35;NET40;ENTITIES6</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Debug-net40\Npgsql.EntityFramework.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release-net40|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Release-net40\</OutputPath> | ||
<DefineConstants>TRACE;WINDOWS;UNMANAGED;NET35;NET40;ENTITIES6</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Release-net40\Npgsql.EntityFramework.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Reference Include="EntityFramework"> | ||
<HintPath>..\packages\EntityFramework.6.0.1\lib\net40\EntityFramework.dll</HintPath> | ||
</Reference> | ||
<Reference Include="EntityFramework.SqlServer"> | ||
<HintPath>..\packages\EntityFramework.6.0.1\lib\net40\EntityFramework.SqlServer.dll</HintPath> | ||
</Reference> | ||
<Reference Include="System" /> | ||
<Reference Include="System.Core" /> | ||
<Reference Include="System.Data" /> | ||
<Reference Include="System.Transactions" /> | ||
<Reference Include="System.Configuration" /> | ||
<Reference Include="System.Xml" /> | ||
<Reference Include="System.ComponentModel.DataAnnotations" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<EmbeddedResource Include="NpgsqlSchema.msl" /> | ||
<EmbeddedResource Include="NpgsqlSchema.ssdl" /> | ||
<EmbeddedResource Include="NpgsqlProviderManifest.Manifest.xml" /> | ||
<None Include="packages.config" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="NpgsqlServices.cs" /> | ||
<Compile Include="NpgsqlProviderManifest.cs" /> | ||
<Compile Include="Properties\AssemblyInfo.cs" /> | ||
<Compile Include="SqlGenerators\SqlBaseGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlDeleteGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlInsertGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlSelectGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlUpdateGenerator.cs" /> | ||
<Compile Include="SqlGenerators\VisitedExpression.cs" /> | ||
<Compile Include="..\CommonAssemblyInfo.cs"> | ||
<Link>Properties\CommonAssemblyInfo.cs</Link> | ||
<SubType>Code</SubType> | ||
</Compile> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ProjectReference Include="..\Npgsql\Npgsql.csproj"> | ||
<Project>{9d13b739-62b1-4190-b386-7a9547304eb3}</Project> | ||
<Name>Npgsql</Name> | ||
</ProjectReference> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | ||
</Project> |
140 changes: 140 additions & 0 deletions
140
Npgsql.EntityFramework/Npgsql.EntityFrameworkLegacy.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,140 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProductVersion>9.0.30729</ProductVersion> | ||
<SchemaVersion>2.0</SchemaVersion> | ||
<ProjectGuid>{100998C4-5B85-11E3-911C-0022198AB089}</ProjectGuid> | ||
<OutputType>Library</OutputType> | ||
<AppDesignerFolder>Properties</AppDesignerFolder> | ||
<AssemblyName>Npgsql.EntityFrameworkLegacy</AssemblyName> | ||
<FileAlignment>512</FileAlignment> | ||
<SignAssembly>true</SignAssembly> | ||
<AssemblyOriginatorKeyFile>..\Npgsql.snk</AssemblyOriginatorKeyFile> | ||
<FileUpgradeFlags> | ||
</FileUpgradeFlags> | ||
<OldToolsVersion>3.5</OldToolsVersion> | ||
<UpgradeBackupLocation /> | ||
<TargetFrameworkProfile /> | ||
<PublishUrl>publish\</PublishUrl> | ||
<Install>true</Install> | ||
<InstallFrom>Disk</InstallFrom> | ||
<UpdateEnabled>false</UpdateEnabled> | ||
<UpdateMode>Foreground</UpdateMode> | ||
<UpdateInterval>7</UpdateInterval> | ||
<UpdateIntervalUnits>Days</UpdateIntervalUnits> | ||
<UpdatePeriodically>false</UpdatePeriodically> | ||
<UpdateRequired>false</UpdateRequired> | ||
<MapFileExtensions>true</MapFileExtensions> | ||
<ApplicationRevision>0</ApplicationRevision> | ||
<ApplicationVersion>1.0.0.%2a</ApplicationVersion> | ||
<IsWebBootstrapper>false</IsWebBootstrapper> | ||
<UseApplicationTrust>false</UseApplicationTrust> | ||
<BootstrapperEnabled>true</BootstrapperEnabled> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug-net45|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Legacy-Debug-net45\</OutputPath> | ||
<DefineConstants>TRACE;DEBUG;WINDOWS;UNMANAGED;NET35;NET40;NET45</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Legacy-Debug-net45\Npgsql.EntityFrameworkLegacy.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release-net45|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Legacy-Release-net45\</OutputPath> | ||
<DefineConstants>TRACE;WINDOWS;UNMANAGED;NET35;NET40;NET45</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Legacy-Release-net45\Npgsql.EntityFrameworkLegacy.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug-net40|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Legacy-Debug-net40\</OutputPath> | ||
<DefineConstants>TRACE;DEBUG;WINDOWS;UNMANAGED;NET35;NET40</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Legacy-Debug-net40\Npgsql.EntityFrameworkLegacy.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release-net40|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Legacy-Release-net40\</OutputPath> | ||
<DefineConstants>TRACE;WINDOWS;UNMANAGED;NET35;NET40</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Legacy-Release-net40\Npgsql.EntityFrameworkLegacy.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug-net35|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Legacy-Debug-net35\</OutputPath> | ||
<DefineConstants>TRACE;DEBUG;WINDOWS;UNMANAGED;NET35</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Legacy-Debug-net35\Npgsql.EntityFrameworkLegacy.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release-net35|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Legacy-Release-net35\</OutputPath> | ||
<DefineConstants>TRACE;WINDOWS;UNMANAGED;NET35</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
<DocumentationFile>bin\Legacy-Release-net35\Npgsql.EntityFrameworkLegacy.xml</DocumentationFile> | ||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Reference Include="System" /> | ||
<Reference Include="System.Core" /> | ||
<Reference Include="System.Data" /> | ||
<Reference Include="System.Data.Entity" /> | ||
<Reference Include="System.Transactions" /> | ||
<Reference Include="System.Configuration" /> | ||
<Reference Include="System.Xml" /> | ||
<Reference Include="System.ComponentModel.DataAnnotations" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<EmbeddedResource Include="NpgsqlSchema.msl" /> | ||
<EmbeddedResource Include="NpgsqlSchema.ssdl" /> | ||
<EmbeddedResource Include="NpgsqlProviderManifest.Manifest.xml" /> | ||
<None Include="packages.config" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="NpgsqlServices.cs" /> | ||
<Compile Include="NpgsqlProviderManifest.cs" /> | ||
<Compile Include="Properties\AssemblyInfo.cs" /> | ||
<Compile Include="SqlGenerators\SqlBaseGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlDeleteGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlInsertGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlSelectGenerator.cs" /> | ||
<Compile Include="SqlGenerators\SqlUpdateGenerator.cs" /> | ||
<Compile Include="SqlGenerators\VisitedExpression.cs" /> | ||
<Compile Include="..\CommonAssemblyInfo.cs"> | ||
<Link>Properties\CommonAssemblyInfo.cs</Link> | ||
<SubType>Code</SubType> | ||
</Compile> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Folder Include="Properties\" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ProjectReference Include="..\Npgsql\Npgsql.csproj"> | ||
<Project>{9d13b739-62b1-4190-b386-7a9547304eb3}</Project> | ||
<Name>Npgsql</Name> | ||
</ProjectReference> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | ||
</Project> |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
using System; | ||
using System.Runtime.CompilerServices; | ||
using System.Security; | ||
using System.Reflection; | ||
using System.Resources; | ||
|
||
// Additional assembly attributes are defined in GlobalAssemblyInfo.cs | ||
|
||
#if ENTITIES6 | ||
[assembly: AssemblyTitleAttribute("Npgsql.EntityFramework")] | ||
[assembly: AssemblyDescriptionAttribute("Postgresql provider for Entity Framework 6 and above")] | ||
#else | ||
[assembly: AssemblyTitleAttribute("Npgsql.EntityFrameworkLegacy")] | ||
[assembly: AssemblyDescriptionAttribute("Postgresql provider for Entity Framework 5 and under")] | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.