Re: [nant-dev] custom functions with the script task

2004-01-08 Thread Ian MacLean
From: "Rodrigo B. de Oliveira" <[EMAIL PROTECTED]> To: "Ian MacLean" <[EMAIL PROTECTED]>; "Jaroslaw Kowalski" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Thursday, January 08, 2004 2:06 PM Subject: Re: [nant-dev] custom functions

Re: [nant-dev] custom functions with the script task

2004-01-08 Thread Jaroslaw Kowalski
Original Message - > From: "Ian MacLean" <[EMAIL PROTECTED]> > To: "Jaroslaw Kowalski" <[EMAIL PROTECTED]> > Cc: <[EMAIL PROTECTED]> > Sent: Thursday, January 08, 2004 6:09 AM > Subject: Re: [nant-dev] custom functions with the scri

Re: [nant-dev] custom functions with the script task

2004-01-08 Thread Rodrigo B. de Oliveira
gt; Cc: <[EMAIL PROTECTED]> Sent: Thursday, January 08, 2004 6:09 AM Subject: Re: [nant-dev] custom functions with the script task > Oh really ? ok in that case the namespace attribute will be required. > Ian > Jaroslaw Kowalski wrote: > > >>I think add the namespace att

Re: [nant-dev] custom functions with the script task

2004-01-08 Thread Ian MacLean
Oh really ? ok in that case the namespace attribute will be required. Ian Jaroslaw Kowalski wrote: I think add the namespace attribute but make it non-required. Just the global namespace if its present. Since none of the built-in functions reside in the global namespace that shouldn't be a problem.

Re: [nant-dev] custom functions with the script task

2004-01-08 Thread Jaroslaw Kowalski
> I think add the namespace attribute but make it non-required. Just the > global namespace if its present. Since none of the built-in functions > reside in the global namespace that shouldn't be a problem. I'm afraid there's no global namespace ;-( And parser does rely on the fact that every func

Re: [nant-dev] custom functions with the script task

2004-01-08 Thread Ian MacLean
I think add the namespace attribute but make it non-required. Just the global namespace if its present. Since none of the built-in functions reside in the global namespace that shouldn't be a problem. Ian OK - I think we can do without the definefunctions attribute though. I'll just make the i

Re: [nant-dev] custom functions with the script task

2004-01-08 Thread Jaroslaw Kowalski
> OK - I think we can do without the definefunctions attribute though. > I'll just make the implicit script class a FunctionSet behind the scenes > and remove the constraint that you have to have a "ScriptMain". What about the namespace? Jarek -

Re: [nant-dev] custom functions with the script task

2004-01-07 Thread Ian MacLean
OK - I think we can do without the definefunctions attribute though. I'll just make the implicit script class a FunctionSet behind the scenes and remove the constraint that you have to have a "ScriptMain". Ian Jaroslaw Kowalski wrote: that should be doable. The class would automatically have t

Re: [nant-dev] custom functions with the script task

2004-01-07 Thread Jaroslaw Kowalski
> that should be doable. The class would automatically have the > FunctionSet attribute added if definefunctions was true. > > but what if you actually wanted to use the constructor to do somthing ? Why ? Who'll call the construtor? AFAIR it's the ExpressionEvaluator who does call functions. And t

Re: [nant-dev] custom functions with the script task

2004-01-07 Thread Ian MacLean
l Message - From: "Jaroslaw Kowalski" <[EMAIL PROTECTED]> To: "Ian MacLean" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Wednesday, January 07, 2004 7:45 AM Subject: Re: [nant-dev] custom functions with the script task Nice. I also though about

Re: [nant-dev] custom functions with the script task

2004-01-07 Thread Jaroslaw Kowalski
> > return "some result "; > That can't be done because you need the type information for formal parameters and returned value. Jarek --- This SF.net email is sponsored by: Perforce Software. Perforce is the Fast Software Co

Re: [nant-dev] custom functions with the script task

2004-01-07 Thread Scott Hernandez
quot;Jaroslaw Kowalski" <[EMAIL PROTECTED]> To: "Ian MacLean" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Wednesday, January 07, 2004 7:45 AM Subject: Re: [nant-dev] custom functions with the script task > Nice. > > I also though about it some time ago. Wo

Re: [nant-dev] custom functions with the script task

2004-01-07 Thread Ian MacLean
override the default name here.</pre><br> <tt>Jarek</tt><br> <br> <tt>- Original Message - From: "Ian MacLean" <[EMAIL PROTECTED]><br> To: <[EMAIL PROTECTED]><br> Sent: Wednesday, January 07, 2004 4:31 PM<br>

Re: [nant-dev] custom functions with the script task

2004-01-07 Thread Jaroslaw Kowalski
al Message - From: "Ian MacLean" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, January 07, 2004 4:31 PM Subject: [nant-dev] custom functions with the script task > I just committed a small change to ScriptTask to allow the definition of > custom funct

[nant-dev] custom functions with the script task

2004-01-07 Thread Ian MacLean
I just committed a small change to ScriptTask to allow the definition of custom functions inside a task instance - see example below:
This is quite nice as it means people can easily prototype new functions without having to compile and load a dedicated task/function assembly. Note that the