public static Notification getFromSharedPreferences(Context context, int notificationId) {
        String optionsJSONString = Manager.getSharedPreferences(context).getString(
            getSharedPreferencesKeyOptions(notificationId), null);

        Log.d(TAG, "Restoring notification from SharedPreferences" +
            ", notificationId=" + notificationId +
            ", options=" + optionsJSONString);
        
        // Notification does not exists
        if (optionsJSONString == null) {
            Log.w(TAG, "Could not restore notification from SharedPreferences, options are null" +
                ", notificationId=" + notificationId);
            return null;
        }
        
        try {
            // Parse options string to JSONObject
            Notification notification = new Notification(context, new JSONObject(optionsJSONString));

            // Restore state of dateTrigger
            // Get occurrence
            int occurrence = Manager.getSharedPreferences(context).getInt(
                notification.getSharedPreferencesKeyOccurrence(), 0);
            
            // Get triger base date
            long triggerBaseTime = Manager.getSharedPreferences(context).getLong(
                notification.getSharedPreferencesKeyTriggerBaseDate(), 0);

            // Get triggerDate
            long triggerTime = Manager.getSharedPreferences(context).getLong(
                notification.getSharedPreferencesKeyTriggerDate(), 0);
            
            TriggerHandler triggerHandler = notification.getTriggerHandler();

            // The saving of occurrence, triggerBaseDate and triggerDate exists since version 1.1.4
            // Before only the options were saved
            // Just caclulate the next trigger from the current time
            // Durring the development of version 1.1.4, first only the occurrence was saved,
            // later also the triggerBaseDate and triggerDate, so check this also
            if (occurrence == 0 || triggerBaseTime == 0 || triggerTime == 0) {
                triggerHandler.getNextTriggerDate();

                // Restore the state of the trigger date
            } else {
                triggerHandler.restoreState(occurrence, new Date(triggerBaseTime), new Date(triggerTime));
            }
            
            Log.d(TAG, "Restored trigger date" +
                ", notificationId=" + notificationId +
                ", occurrence=" + triggerHandler.getOccurrence() +
                ", triggerDate=" + triggerHandler.getTriggerDate() +
                ", triggerBaseDate=" + triggerHandler.getBaseDate());

            return notification;
        } catch (JSONException exception) {
            Log.e(TAG, "Could not parse stored notification options to JSON" + 
                ", notificationId=" + notificationId +
                ", jsonString=" + optionsJSONString,
                exception);
            return null;
        }
    }
Gets a stored notification from the {@link SharedPreferences} by id.
If the notification does not exists, null will be returned.
src/android/Notification.java