Cannot cast ISOElement Object

So in Java this works just fine in a vacuum, but when i try this in my main framework, using grails 2.2.2 this doesnt seem to work which i cannot figure out why. here is the log when i try to do this.

The command is this…
IOSElement el = ((IOSElement)element)
el.setValue(value)

or

((IOSElement)element).setValue(value)

2016-03-22 16:42:17,351 [pool-16-thread-1] ERROR page.BasePage - org.codehaus.groovy.runtime.typehandling.GroovyCastException: Cannot cast object ‘[[IOSDriver: iOS on MAC (14
e6b42c-e10e-42e2-b80c-b9dfe939060c)] -> xpath: //UIAApplication[1]/UIAWindow[2]/UIAScrollView[1]/UIATextField[5]]’ with class ‘com.sun.proxy.$Proxy41’ to class ‘io.appium.java
_client.ios.IOSElement’