Die Reiseauskunft der Deutschen Bahn

oder wie fickt man RESTful-HTTP richtig. Die Deutsche Bahn betreibt seit Jahren ein Auskunftsystem unter der Domain http://reiseauskunft.bahn.de/ dort kann man z.B. Tickets buchen, sich Verbindungen anzeigen lassen oder seit neustem auch einen Zug verfolgen. Damit kann z.B. rausfinden ob ein Zug pünktlich am Bahnhof…

Get the size of an object graph at runtime

At first I have to put a big fat disclaimer up in here: what I am discribing below is totally undocumented and unsupported by microsoft. It is based on findings while I was investigating issues with the MemoryCache in the System.Runtime.Caching assembly. I would not recommend any useage…

Decouple your dependencies

In my spare time I am working on a metro style app for geekli.st, which I wanted to write with CSharp. Since I don't wanted to create hole REST API bindings by myself, I had a look at the official API-wrappers and  found the CSharp bindings for geekli.st…

Encapsulate function calls with Reflection.Emit

My current spare time project YAAF had some requirement that I need to intercept calls to a function. The interceptor then decides if the function gets called or not. But I wanted to parameters to be encapsulated, so the interceptor does not have access to them. The easiest way to…

Happy Birthday omegatau

Well this is my first post on a non software development topic and I would like to say happy birthday to my favourite podcast omegatau for their 100th episode. And I would like to thank Markus and Nora for this awesome project. I think my first episode was number 22…

Yet another AOP framework

In past years I was working with different aspect oriented frameworks. A lot with postsharp in its early days when it was open source and then changed its license to a more closed model. I have helped project to use aop to allow easier development and write less but expressive…

Typesafe interop with native function pointers

The current project I did for a customer faced me with tons of legancy code which was written in C++ years back. This code is supposed to die at some point, but due some requirements the code needed to interact with some .Net / C# with COM Interop. The code uses…