On 2/7/02 12:59 AM, "Jon Scott Stevens" <[EMAIL PROTECTED]> wrote:
> on 2/6/02 9:40 PM, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
>
>> + VelocityContext userContext = new VelocityContext();
>> +
>> + userContext.put("inputfilename", infilename);
>> + userContext.put("outputfilename", outfilename);
>> +
>> + dvsl.setUserContext( userContext );
>
> May I suggest that if you are going to go this route that you create a $dvsl
> tool and add that to the context and then provide methods
> getInputFilename(), getOutputFilename()?
>
> The reason is that once you start down this route, it is easier to point
> people at the javadoc for $dvsl than it is to document each and every item
> you put into the context. It is also easier to keep track of what is in the
> context...
>
Good point, I thought about this when doing it, and needed something to test
some ideas.
The problem is that DVSL doesn't really operate on files, it operates on a
Reader and outputs to a Writer for the most part.
The Ant task is just a shell.
So the concept of 'filename' doesn't make sense to DVSL proper.
I still think that from DVSL's point of view, this is a 'user context'
issue.
Hm. :)
(Point well taken though... I don't like magic context keys either...)
--
Geir Magnusson Jr. [EMAIL PROTECTED]
System and Software Consulting
Be a giant. Take giant steps. Do giant things...
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>