Exemple #1
0
            /// <summary>
            /// Get data operation cache configuration
            /// </summary>
            /// <param name="dataOperationType">Data operation type</param>
            /// <returns>Return Data cache operation configuration</returns>
            public static DataCacheOperationConfiguration GetDataCacheOperationConfiguration(DataOperationType dataOperationType)
            {
                DataCacheOperationConfiguration config = null;

                CacheOperationConfigurations?.TryGetValue(dataOperationType, out config);
                return(config);
            }
Exemple #2
0
 /// <summary>
 /// config cache operation
 /// </summary>
 /// <param name="dataOperationType">Data operation type</param>
 /// <param name="cacheOperationConfiguration">Cache operation configuration</param>
 public static void ConfigureDataCacheOperation(DataOperationType dataOperationType, DataCacheOperationConfiguration cacheOperationConfiguration)
 {
     if (cacheOperationConfiguration == null)
     {
         return;
     }
     if (CacheOperationConfigurations == null)
     {
         CacheOperationConfigurations = new Dictionary <DataOperationType, DataCacheOperationConfiguration>();
     }
     CacheOperationConfigurations[dataOperationType] = cacheOperationConfiguration;
 }