コード例 #1
0
        public MyCouchServerClient(ServerConnectionInfo connectionInfo, MyCouchClientBootstrapper bootstrapper = null)
        {
            Ensure.That(connectionInfo, "connectionInfo").IsNotNull();

            IsDisposed   = false;
            bootstrapper = bootstrapper ?? MyCouchClientBootstrappers.Default;

            Connection = bootstrapper.ServerConnectionFn(connectionInfo);
            Serializer = bootstrapper.SerializerFn();
            Databases  = bootstrapper.DatabasesFn(Connection);
            Replicator = bootstrapper.ReplicatorFn(Connection);
        }
コード例 #2
0
ファイル: MyCouchServerClient.cs プロジェクト: sluu99/mycouch
        public MyCouchServerClient(IServerClientConnection connection, MyCouchClientBootstrapper bootstrapper = null)
        {
            Ensure.That(connection, "connection").IsNotNull();

            Connection = connection;

            bootstrapper = bootstrapper ?? new MyCouchClientBootstrapper();

            Serializer = bootstrapper.SerializerFn();
            Databases = bootstrapper.DatabasesFn(Connection);
            Replicator = bootstrapper.ReplicatorFn(Connection);
            IsDisposed = false;
        }
コード例 #3
0
        public MyCouchServerClient(IServerClientConnection connection, MyCouchClientBootstrapper bootstrapper = null)
        {
            Ensure.That(connection, "connection").IsNotNull();

            Connection = connection;

            bootstrapper = bootstrapper ?? new MyCouchClientBootstrapper();

            Serializer = bootstrapper.SerializerFn();
            Databases  = bootstrapper.DatabasesFn(Connection);
            Replicator = bootstrapper.ReplicatorFn(Connection);
            IsDisposed = false;
        }