<PackageReference Include="Relativity.Transfer.Client" Version="7.2.7" />

PathPair

class PathPair
using System.Security; namespace Aspera.Transfer { internal class PathPair { private string _src; private string _dest; internal string Source => _src; internal string Destination => _dest; internal PathPair(string inSrc) { if (string.IsNullOrEmpty(inSrc)) throw new VerificationException("Source cannot be blank"); _src = inSrc; _dest = ""; } internal PathPair(PathPair inPair) { _src = inPair.Source; _dest = inPair.Destination; } internal PathPair(string inSrc, string inDest) { if (isEmpty(inSrc) || isEmpty(inDest)) throw new VerificationException("You cannot pass a blank src or blank destination"); if ((inDest.EndsWith("/") && inSrc.EndsWith("/")) || (!inDest.EndsWith("/") && !inSrc.EndsWith("/"))) { _src = inSrc; _dest = inDest; return; } throw new VerificationException("Pairs can either be BOTH directories or BOTH files, you cannot mix and match"); } private bool isEmpty(string inString) { if (inString == null || inString.Trim().Length <= 0) return true; return false; } } }