Refactor, and add to/initWith methods

* Separated headers to public and private
* Added to/initWith methods (like toArray, initWithArray, etc)
* Clean up the code a bit