private void InitializeFromString(string content) { _jsonModel = JsonConvert.DeserializeObject <JsonServiceAccountModel>(content); if (_jsonModel == null) { throw new FileLoadException("Incorrect json file was provided"); } FillRsaParams(); }
private void InitializeFromFile(string fileName) { _jsonModel = JsonConvert.DeserializeObject <JsonServiceAccountModel>(File.ReadAllText(fileName)); if (_jsonModel == null) { throw new FileLoadException("Incorrect json file was provided"); } FillRsaParams(); }