If I understand you correctly then you want to access a propoerty of the object passed in as first parameter to getSTringNotNull - correct? Right now - "deep object access" like this is NOT SUPPORTED. The only thing you can do is to capture the first argument. This will in fact call the "toString" method on the object. So - if you developers implement toString to return the value you are interested in then you can use it.