refactor textStorage into StringHandler