This is pretty interesting. Time to read the source code :)