refactor picornerapplication.java, move sharedpreferences related methods out