Added some helper extension methods.