Added some documentationa andeffor checking.