From dcd7e1912305209f758fa0714bee02ce252aecf1 Mon Sep 17 00:00:00 2001 From: Tsahi Asher Date: Sat, 10 Oct 2020 11:28:57 +0300 Subject: [PATCH] move types n OracleConfigurationExtension.cs to their own file #39 --- .../Fluent/IDatabaseOracleConfiguration.cs | 37 ++++++++++++++++ .../IDatabaseOraclePackageConfiguration.cs | 20 +++++++++ .../Fluent/OracleConfigurationExtension.cs | 42 ------------------- 3 files changed, 57 insertions(+), 42 deletions(-) create mode 100644 source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOracleConfiguration.cs create mode 100644 source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOraclePackageConfiguration.cs diff --git a/source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOracleConfiguration.cs b/source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOracleConfiguration.cs new file mode 100644 index 0000000..239a33c --- /dev/null +++ b/source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOracleConfiguration.cs @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. See License.txt in the project root for license information. + +using Oracle.ManagedDataAccess.Client; +using Microsoft.Practices.EnterpriseLibrary.Data.Configuration.Fluent; + +namespace Microsoft.Practices.EnterpriseLibrary.Data.Oracle.Configuration.Fluent +{ + /// + /// Oracle configuration options + /// + public interface IDatabaseOracleConfiguration : IDatabaseConfigurationProperties + { + /// + /// Define an Oracle connection with a connection string. + /// + /// + /// + IDatabaseOracleConfiguration WithConnectionString(string connectionString); + + /// + /// Define an Oracle connection with the + /// + /// + /// +#pragma warning disable 612, 618 + IDatabaseOracleConfiguration WithConnectionString(OracleConnectionStringBuilder builder); +#pragma warning restore 612, 618 + + /// + /// Define an Oracle package with the specified name. + /// + /// + /// + IDatabaseOraclePackageConfiguration WithPackageNamed(string name); + + } +} diff --git a/source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOraclePackageConfiguration.cs b/source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOraclePackageConfiguration.cs new file mode 100644 index 0000000..d63f38f --- /dev/null +++ b/source/Src/Data.Oracle/Configuration/Fluent/IDatabaseOraclePackageConfiguration.cs @@ -0,0 +1,20 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. See License.txt in the project root for license information. + +using Microsoft.Practices.EnterpriseLibrary.Common; +using Microsoft.Practices.EnterpriseLibrary.Data.Configuration.Fluent; + +namespace Microsoft.Practices.EnterpriseLibrary.Data.Oracle.Configuration.Fluent +{ + /// + /// Oracle package configuration options. + /// + public interface IDatabaseOraclePackageConfiguration : IFluentInterface + { + /// + /// Define the prefix for the Oracle package. + /// + /// + /// + IDatabaseConfigurationProperties AndPrefix(string prefix); + } +} diff --git a/source/Src/Data.Oracle/Configuration/Fluent/OracleConfigurationExtension.cs b/source/Src/Data.Oracle/Configuration/Fluent/OracleConfigurationExtension.cs index 8eba1b7..7d570c0 100644 --- a/source/Src/Data.Oracle/Configuration/Fluent/OracleConfigurationExtension.cs +++ b/source/Src/Data.Oracle/Configuration/Fluent/OracleConfigurationExtension.cs @@ -9,48 +9,6 @@ namespace Microsoft.Practices.EnterpriseLibrary.Data.Oracle.Configuration.Fluent { - /// - /// Oracle configuration options - /// - public interface IDatabaseOracleConfiguration : IDatabaseConfigurationProperties - { - /// - /// Define an Oracle connection with a connection string. - /// - /// - /// - IDatabaseOracleConfiguration WithConnectionString(string connectionString); - - /// - /// Define an Oracle connection with the - /// - /// - /// -#pragma warning disable 612, 618 - IDatabaseOracleConfiguration WithConnectionString(OracleConnectionStringBuilder builder); -#pragma warning restore 612, 618 - - /// - /// Define an Oracle package with the specified name. - /// - /// - /// - IDatabaseOraclePackageConfiguration WithPackageNamed(string name); - - } - - /// - /// Oracle package configuration options. - /// - public interface IDatabaseOraclePackageConfiguration : IFluentInterface - { - /// - /// Define the prefix for the Oracle package. - /// - /// - /// - IDatabaseConfigurationProperties AndPrefix(string prefix); - } internal class OracleConfigurationExtension : DatabaseConfigurationExtension,