Nfield.Services.Implementation.NfieldLanguagesService.UpdateAsync C# (CSharp) Method

UpdateAsync() public method

See INfieldLanguagesService.UpdateAsync
public UpdateAsync ( string surveyId, Language language ) : System.Threading.Tasks.Task
surveyId string
language Language
return System.Threading.Tasks.Task
        public Task UpdateAsync(string surveyId, Language language)
        {
            CheckSurveyId(surveyId);

            if (language == null)
            {
                throw new ArgumentNullException("language");
            }

            return Client.PutAsJsonAsync(LanguagesApi(surveyId, 0).AbsoluteUri,
                language).FlattenExceptions();
        }

Usage Example

 public void TestUpdateAsync_SurveyIdIsNull_Throws()
 {
     var target = new NfieldLanguagesService();
     Assert.Throws<ArgumentNullException>(() => UnwrapAggregateException(target.UpdateAsync(null, new Language())));
 }
All Usage Examples Of Nfield.Services.Implementation.NfieldLanguagesService::UpdateAsync