예제 #1
0
        public static List <ModTeamMember> LoadModTeam(int modId)
        {
            string filePath = CacheClient.GenerateModTeamFilePath(modId);
            var    modTeam  = CacheClient.ReadJsonObjectFile <List <ModTeamMember> >(filePath);

            return(modTeam);
        }
예제 #2
0
        /// <summary>Stores a mod team's data in the cache.</summary>
        public static bool SaveModTeam(int modId,
                                       List <ModTeamMember> modTeam)
        {
            Debug.Assert(modTeam != null);

            string filePath = CacheClient.GenerateModTeamFilePath(modId);

            return(IOUtilities.WriteJsonObjectFile(filePath, modTeam));
        }
예제 #3
0
        /// <summary>Retrieves a mod team's data from the cache.</summary>
        public static List <ModTeamMember> LoadModTeam(int modId)
        {
            string filePath = CacheClient.GenerateModTeamFilePath(modId);
            List <ModTeamMember> modTeam;

            LocalDataStorage.ReadJSONFile(filePath, out modTeam);

            return(modTeam);
        }
예제 #4
0
        /// <summary>Stores a mod team's data in the cache.</summary>
        public static bool SaveModTeam(int modId,
                                       List <ModTeamMember> modTeam)
        {
            Debug.Assert(modTeam != null);

            string filePath = CacheClient.GenerateModTeamFilePath(modId);

            return(LocalDataStorage.WriteJSONFile(filePath, modTeam));
        }
예제 #5
0
        public static void SaveModTeam(int modId,
                                       List <ModTeamMember> modTeam)
        {
            Debug.Assert(modId > 0,
                         "[mod.io] Cannot cache a mod team without a mod id");

            string filePath = CacheClient.GenerateModTeamFilePath(modId);

            CacheClient.WriteJsonObjectFile(filePath, modTeam);
        }
예제 #6
0
 public static void DeleteModTeam(int modId)
 {
     CacheClient.DeleteFile(CacheClient.GenerateModTeamFilePath(modId));
 }
예제 #7
0
 /// <summary>Deletes a mod team's data from the cache.</summary>
 public static bool DeleteModTeam(int modId)
 {
     return(IOUtilities.DeleteFile(CacheClient.GenerateModTeamFilePath(modId)));
 }
예제 #8
0
        /// <summary>Deletes a mod team's data from the cache.</summary>
        public static bool DeleteModTeam(int modId)
        {
            string path = CacheClient.GenerateModTeamFilePath(modId);

            return(LocalDataStorage.DeleteFile(path));
        }