cleaned up API by moving internal functions and properties to _private namespace