Finished the first pass of implementation with documentation.