It is a common practice to validate function arguments before running actual code. Usually validation looks like that: public void Update(Car entity) { if(entity ==null) throw new ArgumentNullException("entity"); } There is nothing wrong with this code, however we have to repeat this piece of code in every function. Of course we could create some helper class for argument validation and call approperiate validation function before launching...
Strona głównaWindows
Źródło:
tomasz-net.blogspot.com
Dziel się z innymi:
Windows 4166 dni, 18 godzin, 3 minuty temu 33 pokaż kod licznika zwiń
Polecamy
Najaktywniejsi w tym miesiącu
Nadchodzące wydarzenia
.Net
.net core
architektura
ASP .NET
asp.net
Asp.Net Core
ASP.NET MVC
Azure
C#
C# .NET
certyfikacja
certyfikat
cloud
csharp
daj sie poznac 2017
Daj się poznać
Daj Się Poznać 2017
dajsiepoznac
DDD
docker
dotnet
dsp2017
egzamin
Entity Framework
F#
git
JavaScript
jQuery
konferencja
Linq
mvc
MVVM
Narzędzia
performance
podcast
praca
programowanie
SharePoint
Silverlight
SQL
sql server
TDD
testy
Visual Studio
WCF
Windows
windows phone
WPF
Wzorce projektowe
Xamarin