コード例 #1
0
 public async Task UpdateSessionAsync(LoginSession session)
 {
     await _client.ReplaceDocumentAsync(UriFactory.CreateDocumentUri(_databaseId, SESSIONS_DOCUMENT_COLLECTION_ID, session.Id), session);
 }
コード例 #2
0
        public async Task <LoginSession> CreateSessionAsync(LoginSession session)
        {
            var result = await _client.CreateDocumentAsync(GetSessionsCollectionUri(), session);

            return(JsonConvert.DeserializeObject <LoginSession>(result.Resource.ToString()));
        }