예제 #1
0
        internal static void RemoveFactory(Factory factory)
        {
            DataSaver <byte[]> .Remove("factory" + factory.Id);

            SavedData.Factories.RemoveAll(x => x.Id == factory.Id);
            Update();
        }
예제 #2
0
        private async static void downloadImage(string url, string name)
        {
            var client = new WebClient();
            var stream = await client.OpenReadTaskAsync(new Uri(url, UriKind.Absolute));

            var bytes = ReadFully(stream);

            DataSaver <byte[]> .Remove(name);

            DataSaver <byte[]> .Save(name, bytes);

            Update();
        }