Beispiel #1
0
        public async Task <T> ReadAsync(string filePath)
        {
            using (var ts = new TextStore())
            {
                var json = await ts.ReadAsync(filePath);

                return(JsonConvert.DeserializeObject <T>(json, _settings));
            }
        }
Beispiel #2
0
        public async Task WriteAsync(string filePath, T content)
        {
            using (var ts = new TextStore())
            {
                var json = JsonConvert.SerializeObject(content, _settings);

                await ts.WriteAsync(filePath, json);
            }
        }