csharp/2881099/csredis/src/CSRedisCore/IRedisClient.cs

IRedisClient.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace CSRedis
{
    /// 
    /// Common properties of the RedisClient
    /// 
    public interface IRedisClient : IDisposable
    {
        /// 
        /// Occurs when a subscription message is received
        /// 
        event EventHandler SubscriptionReceived;

        /// 
        /// Occurs when a subscription channel is added or removed
        /// 
        event EventHandler SubscriptionChanged;

        /// 
        /// Occurs when a transaction command is acknowledged by the server
        /// 
        event EventHandler TransactionQueued;

        /// 
        /// Occurs when a monitor message is received
        /// 
        event EventHandler MonitorReceived;

        /// 
        /// Occurs when the connection has sucessfully reconnected
        /// 
        event EventHandler Connected;


        /// 
        /// Get the Redis server hostname
        /// 
        string Host { get; }

        /// 
        /// Get the Redis server port
        /// 
        int Port { get; }

        /// 
        /// Get a value indicating whether the Redis client is connected to the server
        /// 
        bool IsConnected { get; }

        /// 
        /// Get or set the string encoding used to communicate with the server
        /// 
        Encoding Encoding { get; set; }

        /// 
        /// Get or set the connection read timeout (milliseconds)
        /// 
        int ReceiveTimeout { get; set; }

        /// 
        /// Get or set the connection send timeout (milliseconds)
        /// 
        int SendTimeout { get; set; }

        /// 
        /// Get or set the number of times to attempt a reconnect after a connection fails
        /// 
        int ReconnectAttempts { get; set; }

        /// 
        /// Get or set the amount of time (milliseconds) to wait between reconnect attempts
        /// 
        int ReconnectWait { get; set; }
    }
}