Changed visibility to public for some methods.