Ejemplo n.º 1
0
    public async Task <DestinationFolder> AddOrUpdateDestinationFolderAsync(DestinationFolder destinationFolder)
    {
        var request = _mapper.Map <DestinationFolderCreateRequest>(destinationFolder);

        var result = await _destinationFolderRoomClient.CreateOrUpdateAsync(
            destinationFolder.CollectionId,
            request);

        return(_mapper.Map <DestinationFolder>(result));
    }
 /// <summary>
 /// CreateOrUpdate or update a destination folder for collection.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='collectionId'>
 /// The collection id.
 /// </param>
 /// <param name='body'>
 /// Destination folder parameters.
 /// </param>
 public static DestinationFolderResponse CreateOrUpdate(this IDestinationFolder operations, System.Guid collectionId, DestinationFolderCreateRequest body = default(DestinationFolderCreateRequest))
 {
     return(operations.CreateOrUpdateAsync(collectionId, body).GetAwaiter().GetResult());
 }