On Sun, Apr 26, 2020 at 5:43 PM Peter McNeil wrote:
> G'day David
>
> On 25/4/20 6:17 am, David Karr wrote:
> > Lately my only Groovy work is scripted pipelines in Jenkins, version
> > 2.89.4 .
> >
> > I'm working with an api that is somewhat dumb in one respect. The
> > method we call takes
G'day David
On 25/4/20 6:17 am, David Karr wrote:
Lately my only Groovy work is scripted pipelines in Jenkins, version
2.89.4 .
I'm working with an api that is somewhat dumb in one respect. The
method we call takes ~25 parameters. We send them as named
parameters. One of the parameters is
;
>
>
> Sent from Mail <https://go.microsoft.com/fwlink/?LinkId=550986> for
> Windows 10
>
>
>
> *From: *David Karr
> *Sent: *Sunday, April 26, 2020 11:34 AM
> *To: *users@groovy.apache.org
> *Subject: *Re: Re: Strategy for optionally excluding a named method
ent from Mail for Windows 10 From: David KarrSent: Sunday, April 26, 2020 11:34 AMTo: users@groovy.apache.orgSubject: Re: Re: Strategy for optionally excluding a named method parameter? On Sat, Apr 25, 2020 at 10:42 PM Rathinavelu <rathinav...@gmail.com> wrote:Sir, I do not understand the NEED
gain to
describe what I have "correctly pointed out".
*Sent: *Sunday, April 26, 2020 9:00 AM
> *To: *users@groovy.apache.org; David Karr
> *Subject: *Re: Strategy for optionally excluding a named method parameter?
>
>
>
> It’s doing what you programmed it to do.
&
. They are combined here. Those are the problems addressed. First line of my mailBoth named and varagsays that. Sent from Mail for Windows 10 From: CFoutsSent: Sunday, April 26, 2020 9:00 AMTo: users@groovy.apache.org; David KarrSubject: Re: Strategy for optionally excluding a named method parameter? It’s
what you have
string
false string
true
From: Rathinavelu
Reply-To:
Date: Saturday, April 25, 2020 at 9:23 PM
To: "users@groovy.apache.org" ,
"users@groovy.apache.org" , David Karr
Subject: RE: Re: Strategy for optionally excluding a named method param
n the middle perhaps is “invisible input”. Last output has no [null]T.Rathinavelu Sent from Mail for Windows 10 From: MGSent: Sunday, April 26, 2020 5:00 AMTo: users@groovy.apache.org; David KarrSubject: Re: Strategy for optionally excluding a named method parameter? Hi David,since, as was mention
Sent from Mail for Windows 10 From: RathinaveluSent: Sunday, April 26, 2020 5:29 AMTo: users@groovy.apache.orgSubject: RE: Re: Strategy for optionally excluding a named method parameter? Sirs, 1.We need both named parameters implemented through map and, also varags if we want to call
e:false) g(one:true) The output is : true falseThanking you,T.RathinaveluSent from Mail for Windows 10 From: MGSent: Sunday, April 26, 2020 5:00 AMTo: users@groovy.apache.org; David KarrSubject: Re: Strategy for optionally excluding a named method parameter? Hi
Hi David,
since, as was mentioned, named parameters are implemented as a map
underneath in Groovy, you should be able to remove the map entry of the
parameter you do not want to pass, though I did not try this myself...
Cheers,
mg
On 25/04/2020 20:57, David Karr wrote:
On Sat, Apr 25,
On Sat, Apr 25, 2020 at 2:00 AM Rathinavelu wrote:
> Named parameters are not available in Groovy, say, as in Python., though
> they say it is. Groovy has only mapped parameters. The earlier mail works
> for a single ‘named’ parameter; if there are more parameters Groovy does
> not work as
Named parameters are not available in Groovy, say, as in Python., though they say it is. Groovy has only mapped parameters. The earlier mail works for a single ‘named’ parameter; if there are more parameters Groovy does not work as ‘expected’; it treats them only as positional parameters.Kindly
Sir, I find no problem.groovy> def f(boolean b) { println b} groovy> f(b=false) // namedgroovy> f(b=!false) groovy> boolean bb = 7==70 groovy> f(b=bb) groovy> bb = 7==7 groovy> f(b=bb) falsetruefalsetruePerhaps I do not understand the situation. May you kindly post me the failing
14 matches
Mail list logo