Update JSDoc comments. Rename some methods as privated.