android: check if value is present in Shared Preferences
<p>I'm creating Shared Preferences as follows</p>

<pre><code>preferences = getSharedPreferences("text", 0);
final Editor editor = preferences.edit();

String s1 = serverIP.getText().toString();
String s2 = serverPort.getText().toString();
String s3 = syncPass.getText().toString();
String s4 = proxyServer.getText().toString();
String s5 = proxyPort.getText().toString();

editor.putString("SERVERIP", s1);
editor.putString("SERVERPORT", s2);
editor.putString("SYNCPASS", s3);
editor.putString("PROXYSERVER", s3);
editor.putString("PROXYPORT", s3);
</code></pre>

<p>and onCreate i want to display the values in new set of TextView, but the first time i will not have any values stored in the shared preferences and will get a NULL Pointer exception.... <strong>So i want to know if there is any inbuilt method which can check if the shared preferences contains any value or no</strong>,,, so that i can check for the value presence and then Replace the New set of textviews with the preferences value.. </p>
