Gaddzeit.Kata.Domain.Address.PerformConstructorNullChecks C# (CSharp) Méthode

PerformConstructorNullChecks() private static méthode

private static PerformConstructorNullChecks ( string street, string city, string province ) : void
street string
city string
province string
Résultat void
        private static void PerformConstructorNullChecks(string street, string city, string province)
        {
            if (string.IsNullOrEmpty(street))
                throw new ArgumentException("You must provide a non-null address.");
            if (string.IsNullOrEmpty(city))
                throw new ArgumentException("You must provide a non-null city.");
            if (string.IsNullOrEmpty(province))
                throw new ArgumentException("You must provide a non-null province.");
        }