How to return a custom HTTP status code using WebAPI 2

When developing a RESTful API we sometimes need to return an HTTP status code that is not included in Microsoft's HttpStatusCode enumeration. For example this is the case for HTTP 423 (Locked) and others. This post will give you an example on how to return such a custom HTTP status…

How to create a deep copy of an object

There might be some situations where we want to create an exact copy of a complex object graph. Like other coding languages C# does't provide any out of the box solution for this. We therefor have to come up with our own one…