Cannot get line number through ScriptException

2017-05-14 Thread Chandler Lv
Hi all, I use groovy in my java application. With JSR223, first compile, then eval. Everything is good except for one thing. It looks like that I cannot get the line number through catching ScriptException when there is something wrong with my scripts. So I checkout the source code. In GroovyScri

Re: Binary to Base64 Conversion

2017-05-14 Thread RJ
the first problem is encoding. its coming in an encoded format that decodeBase64 cannot understand. Whats the equivalent of the following in groovy script? env.put("java.naming.ldap.attributes.binary","APPUID"); Thanks Guys On Sun, May 14, 2017 at 6:59 AM, Jeff Cave wrote: > I don't think th

Re: Binary to Base64 Conversion

2017-05-14 Thread Jeff Cave
I don't think this is not a Groovy problem, so much as a general programming problem. The first thing I would point out is that in your example APPUID is not base64encoded, there is nothing to base64decode. https://en.wikipedia.org/wiki/Base64 I notice that in your example, APPUID is 16 charact

Re: Binary to Base64 Conversion

2017-05-14 Thread RJ
getBytes() disrupts the base64 format: org.codehaus.groovy.runtime.InvokerInvocationException: groovy.lang.MissingMethodException: No signature of method: [B.decodeBase64() is applicable for argument types: () values: [] Possible solutions: encodeBase64(), encodeBase64(boolean) Thanks On Sat,