Ejemplo n.º 1
0
        /// <summary>
        /// Adds an expiration policy to the composition.
        /// </summary>
        /// <param name="expirationPolicy">
        /// The expiration policy.
        /// </param>
        /// <returns>
        /// The <see cref="CompositeExpirationPolicy"/>.
        /// </returns>
        public CompositeExpirationPolicy Add(ExpirationPolicy expirationPolicy)
        {
            _synchronizationContext.Execute(() => _expirationPolicies.Add(expirationPolicy));

            return(this);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Adds an expiration policy to the composition.
        /// </summary>
        /// <param name="expirationPolicy">
        /// The expiration policy.
        /// </param>
        /// <returns>
        /// The <see cref="CompositeExpirationPolicy"/>.
        /// </returns>
        public CompositeExpirationPolicy Add(ExpirationPolicy expirationPolicy)
        {
            _synchronizationContext.Execute(() => _expirationPolicies.Add(expirationPolicy));

            return this;
        }