src/PowerAuth/jni/SessionJNI.cpp
//
// public native int changeUserPassword(Password oldPassword, Password newPassword);
//
public native int changeUserPassword(Password oldPassword, Password newPassword).
public native int changeUserPassword ( Password oldPassword Password newPassword ) .
CC7_JNI_METHOD_PARAMS(jint, changeUserPassword, jobject oldPassword, jobject newPassword)
{
	auto session = CC7_THIS_OBJ();
	if (!session || !oldPassword || !newPassword) {
		CC7_ASSERT(false, "Missing param or internal handle.");
		return EC_WrongParam;
	}
	Password * oldPasswordObj = GetCppPasswordFromJavaObject(env, oldPassword);
	Password * newPasswordObj = GetCppPasswordFromJavaObject(env, newPassword);
	if (!oldPasswordObj || !newPasswordObj) {
		return EC_WrongParam;
	}
	return session->changeUserPassword(oldPasswordObj->passwordData(), newPasswordObj->passwordData());
}
CC7_JNI_METHOD_PARAMS ( jint , changeUserPassword , jobject oldPassword , jobject newPassword ) { auto session = CC7_THIS_OBJ ( ) ; if ( ! session || ! oldPassword || ! newPassword ) { CC7_ASSERT ( false , " " ) ; return EC_WrongParam ; } Password * oldPasswordObj = GetCppPasswordFromJavaObject ( env , oldPassword ) ; Password * newPasswordObj = GetCppPasswordFromJavaObject ( env , newPassword ) ; if ( ! oldPasswordObj || ! newPasswordObj ) { return EC_WrongParam ; } return session -> changeUserPassword ( oldPasswordObj -> passwordData ( ) , newPasswordObj -> passwordData ( ) ) ; }
public native int changeUserPassword(Password oldPassword, Password newPassword);
public native int changeUserPassword ( Password oldPassword Password newPassword ) ;
// Call C++ session