Skip to content

Commit

Permalink
move types n OracleConfigurationExtension.cs to their own file
Browse files Browse the repository at this point in the history
  • Loading branch information
tsahi committed Oct 10, 2020
1 parent d301cc5 commit dcd7e19
Show file tree
Hide file tree
Showing 3 changed files with 57 additions and 42 deletions.
Original file line number Diff line number Diff line change
@@ -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
{
/// <summary>
/// Oracle configuration options
/// </summary>
public interface IDatabaseOracleConfiguration : IDatabaseConfigurationProperties
{
/// <summary>
/// Define an Oracle connection with a connection string.
/// </summary>
/// <param name="connectionString"></param>
/// <returns></returns>
IDatabaseOracleConfiguration WithConnectionString(string connectionString);

/// <summary>
/// Define an Oracle connection with the <see cref="OracleConnectionStringBuilder"/>
/// </summary>
/// <param name="builder"></param>
/// <returns></returns>
#pragma warning disable 612, 618
IDatabaseOracleConfiguration WithConnectionString(OracleConnectionStringBuilder builder);
#pragma warning restore 612, 618

/// <summary>
/// Define an Oracle package with the specified name.
/// </summary>
/// <param name="name"></param>
/// <returns></returns>
IDatabaseOraclePackageConfiguration WithPackageNamed(string name);

}
}
Original file line number Diff line number Diff line change
@@ -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
{
/// <summary>
/// Oracle package configuration options.
/// </summary>
public interface IDatabaseOraclePackageConfiguration : IFluentInterface
{
/// <summary>
/// Define the prefix for the Oracle package.
/// </summary>
/// <param name="prefix"></param>
/// <returns></returns>
IDatabaseConfigurationProperties AndPrefix(string prefix);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,48 +9,6 @@

namespace Microsoft.Practices.EnterpriseLibrary.Data.Oracle.Configuration.Fluent
{
/// <summary>
/// Oracle configuration options
/// </summary>
public interface IDatabaseOracleConfiguration : IDatabaseConfigurationProperties
{
/// <summary>
/// Define an Oracle connection with a connection string.
/// </summary>
/// <param name="connectionString"></param>
/// <returns></returns>
IDatabaseOracleConfiguration WithConnectionString(string connectionString);

/// <summary>
/// Define an Oracle connection with the <see cref="OracleConnectionStringBuilder"/>
/// </summary>
/// <param name="builder"></param>
/// <returns></returns>
#pragma warning disable 612, 618
IDatabaseOracleConfiguration WithConnectionString(OracleConnectionStringBuilder builder);
#pragma warning restore 612, 618

/// <summary>
/// Define an Oracle package with the specified name.
/// </summary>
/// <param name="name"></param>
/// <returns></returns>
IDatabaseOraclePackageConfiguration WithPackageNamed(string name);

}

/// <summary>
/// Oracle package configuration options.
/// </summary>
public interface IDatabaseOraclePackageConfiguration : IFluentInterface
{
/// <summary>
/// Define the prefix for the Oracle package.
/// </summary>
/// <param name="prefix"></param>
/// <returns></returns>
IDatabaseConfigurationProperties AndPrefix(string prefix);
}


internal class OracleConfigurationExtension : DatabaseConfigurationExtension,
Expand Down

0 comments on commit dcd7e19

Please sign in to comment.