0

This is how I pass data

SharedPreferences pref = getApplicationContext().getSharedPreferences("FingerPrint", 0);
                            SharedPreferences.Editor editor = pref.edit();
                            editor.putString("fingerImage", encodedWsq);
                            editor.apply();

And I want to access "fingerImage" data to my nativescript project, that is java files are exported to jar file.

Markus Kauppinen
  • 3,025
  • 4
  • 20
  • 30
cshine
  • 27
  • 1
  • 10

1 Answers1

1

Perhaps you could directly use the application-settings NativeScript module (which is using SharedPrefferences behind the scenes) to set & get the values.

TypeScript example

import { setString, getString } from "tns-core-modules/application-settings";
setString("fingerImage", encodedWsq);
const myString = getString("fingerImage");
Nick Iliev
  • 9,610
  • 3
  • 35
  • 89