Documentation / Sample Code Update

Updated all the documentation to no longer reference deprecated code, and to be a little bit clearer.
Changed sample code to compile without deprecation warnings.