only use persistent state in "addDataToString()"