use getObject instead of getValue to access frame variables

Since you set only Object values, you should use the more efficient getObject to retrieve them. If you want to have primitive types as well, you should specialize reads and use the correspending typed getters.