This file contains hidden or 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
public class OracleManagedDataClientDriver : ReflectionBasedDriver, IEmbeddedBatcherFactoryProvider | |
{ | |
private const string driverAssemblyName = "Oracle.ManagedDataAccess"; | |
private const string connectionTypeName = "Oracle.ManagedDataAccess.Client.OracleConnection"; | |
private const string commandTypeName = "Oracle.ManagedDataAccess.Client.OracleCommand"; | |
private static readonly SqlType GuidSqlType = new SqlType(DbType.Binary, 16); | |
private readonly PropertyInfo oracleCommandBindByName; | |
private readonly PropertyInfo oracleDbType; | |
private readonly object oracleDbTypeRefCursor; |
This file contains hidden or 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
public class WindsorConfigurationTests | |
{ | |
private readonly WindsorContainer container; | |
public WindsorConfigurationTests() | |
{ | |
container = new WindsorContainer(); | |
container.Install(FromAssembly.Named("AppX")); | |
} |
This file contains hidden or 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
public static IList<TRes> ListAs<TRes>(this IQueryOver qry, TRes resultByExample) | |
{ | |
var ctor = typeof (TRes).GetConstructors().First(); | |
return qry.UnderlyingCriteria | |
.SetResultTransformer(Transformers.AliasToBeanConstructor(ctor)) | |
.List<TRes>(); | |
} | |
[Fact] | |
public void ListAs_Should_CastQueryOverResultToTypeSameAsSupliedExampleInstance() |
This file contains hidden or 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
public static class NativeMethods | |
{ | |
[DllImport("coredll")] | |
public extern static bool CloseHandle(IntPtr handle); | |
[DllImport("coredll", CharSet = CharSet.Auto, SetLastError = true)] | |
public static extern bool DeviceIoControl( | |
IntPtr hDevice, | |
int dwIoControlCode, | |
[In] int[] inBuffer, |
This file contains hidden or 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using FluentNHibernate.Cfg; | |
using FluentNHibernate.Cfg.Db; | |
using FluentNHibernate.Mapping; | |
using NHibernate; | |
using NHibernate.Cfg; | |
using NHibernate.Tool.hbm2ddl; |
This file contains hidden or 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
public delegate DateTime CurrentDateTimeDelegate(); | |
public static class CurrentDateTime | |
{ | |
public static readonly CurrentDateTimeDelegate DefaultDelegate = () => DateTime.Now; | |
} | |
public class ClassX | |
{ | |
private CurrentDateTimeDelegate currentDateTime = CurrentDateTime.DefaultDelegate; |
This file contains hidden or 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
using System; | |
using System.Drawing; | |
using System.IO; | |
using System.Text; | |
using ICSharpCode.SharpZipLib.Checksums; | |
using ICSharpCode.SharpZipLib.Zip.Compression.Streams; | |
namespace PNG.Net | |
{ | |
public interface IPngStreamWriter |
This file contains hidden or 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
public class Ciselnik | |
{ | |
public long Id{ get; set;} | |
public LocalizedText Name{ get; set;} | |
public IEnumerable<PolozkaCiselniku> Items { get; set; } | |
} | |
public class PolozkaCiselniku | |
{ | |
public long Id{ get; set;} |
This file contains hidden or 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
public class VirtualWcfPathProvider : VirtualPathProvider | |
{ | |
public static readonly string VirtualWcfDirectoryName = "~/Services"; // Must start with "~/", must not end with "/". | |
private readonly IDictionary<string, Type> serviceMap; | |
public VirtualWcfPathProvider(IDictionary<string, Type> serviceMap) | |
{ | |
this.serviceMap = serviceMap; | |
} |
This file contains hidden or 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
public class WcfApplicationContext: IApplicationContext | |
{ | |
private readonly IRepository<User> userRepository; | |
public WcfApplicationContext(IRepository<User> userRepository) | |
{ | |
this.userRepository = userRepository; | |
} | |
public User CurrentUser |
NewerOlder