Example #1
0
        internal static void Clear()
        {
            ValidateResultRepositoryBase.ClearBase();

            CookieDomain     = null;
            CookieExpiration = TimeSpan.FromMinutes(20);
        }
Example #2
0
        private static void LoadConfiguration()
        {
            ValidateResultRepositoryBase.LoadBaseConfiguration();

            SettingsSection settings = SettingsSection.GetSection();

            if (settings != null && settings.RepositorySettings != null)
            {
                CookieDomain = GetValue("CookieDomain", settings.RepositorySettings);

                SetTimespanFromRepositorySettings(
                    settings.RepositorySettings, "CookieExpiration", (value) => CookieExpiration = value);
            }
        }
Example #3
0
        /// <summary>
        /// Configures the CookieValidateResultRepository. This method will override any previous calls and configuration in config files.
        /// </summary>
        /// <param name="cookieDomain">The domain name of the cookie scope</param>
        /// <param name="cookieExpiration">The amount of time the user can stay on the website before sent to the queue. The time will be extended each time validation is performed.</param>
        /// <param name="idleExpiration">The amount of time the user can stay on the website before sent to the queue if the queue is in Idle mode. The time will not be extended each time validation is performed.</param>
        /// <param name="extendValidity">If false, the time will not be extended each time validation is performed.</param>
        public static void Configure(
            string cookieDomain       = null,
            TimeSpan cookieExpiration = default(TimeSpan),
            TimeSpan idleExpiration   = default(TimeSpan),
            bool extendValidity       = true)
        {
            ValidateResultRepositoryBase.ConfigureBase(idleExpiration, extendValidity);

            if (cookieDomain != null)
            {
                CookieDomain = cookieDomain;
            }
            if (cookieExpiration != default(TimeSpan))
            {
                CookieExpiration = cookieExpiration;
            }
        }
Example #4
0
 internal static void Clear()
 {
     ValidateResultRepositoryBase.ClearBase();
 }
Example #5
0
 /// <summary>
 /// Configures the SessionValidateResultRepository. This method will override any previous calls and configuration in config files.
 /// </summary>
 /// <param name="idleExpiration">The amount of time the user can stay on the website before sent to the queue if the queue is in Idle mode. The time will not be extended each time validation is performed.</param>
 /// <param name="extendValidity">If false, the time will not be extended each time validation is performed.</param>
 public static void Configure(
     TimeSpan idleExpiration = default(TimeSpan),
     bool extendValidity     = true)
 {
     ValidateResultRepositoryBase.ConfigureBase(idleExpiration, extendValidity);
 }
Example #6
0
 private static void LoadConfiguration()
 {
     ValidateResultRepositoryBase.LoadBaseConfiguration();
 }