123456789101112131415161718192021222324252627282930313233343536373839404142 |
- using System;
- using System.Collections.Generic;
- using System.Text;
- using CB.Common;
- namespace CB.Cache.MemCached
- {
-
-
-
-
- public class MemCachedConfig
- {
- private static object _lockHelper = new object();
- private static MemCachedConfigInfo config = null;
- public static void LoadConfig(string configfilepath)
- {
- if (config == null)
- {
- lock (_lockHelper)
- {
- if (config == null)
- {
- config = JSONUtil.ParseFormByJson<MemCachedConfigInfo>(Utils.ReadFile(configfilepath));
- }
- }
- }
- }
-
-
-
-
- public static MemCachedConfigInfo GetConfig()
- {
- return config;
- }
- }
- }
|