Moved JNI intializations and management to class.