This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Microsoft.TeamFoundation.Build.Client; | |
| using Microsoft.TeamFoundation.Client; | |
| using Microsoft.Win32; | |
| using System; | |
| using System.Collections.Generic; | |
| using System.Diagnostics; | |
| using System.Drawing; | |
| using System.Linq; | |
| using System.Runtime.InteropServices; | |
| using System.Text; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class EWayOffsitePaymentSettings : IPaymentSettings | |
| { | |
| public string PaymentType | |
| { | |
| get { return "Sale"; } | |
| set { } | |
| } | |
| public string[] ProcessorCreditCards | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #requires -version 2.0 | |
| param ( | |
| [parameter(Mandatory=$true)] | |
| [string] | |
| $Path | |
| ) | |
| $tool= "e:\tools\NuGet.exe" | |
| $files = Get-ChildItem -Path $Path -Filter Microsoft.TeamFoundation.*.dll -recurse |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Microsoft.TeamFoundation.TestManagement.Controller; | |
| using Microsoft.VisualStudio.TestTools.Common; | |
| using System; | |
| using System.Collections; | |
| using System.Collections.Generic; | |
| using System.Collections.Specialized; | |
| using System.IO; | |
| using System.Linq; | |
| using System.Reflection; | |
| using System.Runtime.Serialization; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Microsoft.TeamFoundation.Client; | |
| using Microsoft.TeamFoundation.Framework.Client; | |
| using Microsoft.TeamFoundation.Framework.Common; | |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Text; | |
| using System.Threading.Tasks; | |
| using System.Xml; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| foreach (var child in source.ChildCollection) | |
| { | |
| var targetChild = target.ChildCollection.SingleOrDefault(c => c.Equals(child)); //overwrite Equals or replace comparison with an Id comparison | |
| if (targetChild == null) | |
| target.ChildCollection.Add(Mapper.Map<SourceChildType, TargetChildType>(child)); | |
| else | |
| Mapper.Map(child, targetChild); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public ActionResult View(int id) | |
| { | |
| var entity = LoadFromDatabase(id); | |
| return AutoMap<ViewResult>(View(entity)); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [AutoMap(typeof(ViewModel)] | |
| public ActionResult View(int id) | |
| { | |
| var entity = LoadFromDatabase(id); | |
| return View(entity); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public ActionResult View(int id) | |
| { | |
| var entity = LoadFromDatabase(id); | |
| var viewModel = Mapper.Map<ViewModel>(entity); | |
| return View(viewModel); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class PaginationMapper : IObjectMapper | |
| { | |
| private IMappingEngineRunner _mapper; | |
| public T Map<T>(object source) | |
| { | |
| TypeMap typeMap = _mapper.ConfigurationProvider.FindTypeMapFor(source, source.GetType(), typeof(T)); | |
| MappingOperationOptions mappingOperationOptions = new MappingOperationOptions(); | |
| ResolutionContext resolutionContext = new ResolutionContext(typeMap, source, source.GetType(), typeof(T), mappingOperationOptions); | |
| return (T)_mapper.Map(resolutionContext); | |
| } |
NewerOlder