Пример #1
0
 public override Task UpdateAsync(UpdateParameter parameter)
 {
     var dao = new PeercastDao(Address);
     return dao.SetMetaAsync(parameter.Name, parameter.Genre, parameter.Description,
             parameter.ContactUrl, parameter.Comment,
             parameter.TrackArtist, parameter.TrackTitle, parameter.TrackAlbum,
             parameter.TrackGenre, parameter.TrackContact)
         .ContinueWith(t => dao.Dispose());
 }
Пример #2
0
 private Task<XmlStatus> GetXmlStatusAsync()
 {
     var dao = new PeercastDao(Address);
     return dao.GetViewXmlAsync().ContinueWith(t =>
     {
         dao.Dispose();
         return new XmlStatus(t.Result);
     });
 }
Пример #3
0
 public override Task StopAsync(string id)
 {
     var dao = new PeercastDao(Address);
     return dao.StopAsync(id).ContinueWith(t => dao.Dispose());
 }