Its been awhile since I last tried to sort this out, but iirc, at the
very beginning of torque all properties were given through the ant task
and had to have setters. Jason did not like this and made the
properties available in the templates without having to give them in the
ant xml. This is good since most of the logic is in the templates
(which is my doing and I am fully supportive of attempts to move logic
into the model). But all the properties are not available to the java
code. Hopefully I am wrong and I missed someone making this possible,
but I think that if you need a property available to the model, you will
have to define getters/setters, put it into build-torque.xml and pass
the value on to the model.
john mcnally
On Mon, 2002-07-29 at 20:46, Stephen Haberman wrote:
> >
> > Modified: src/conf build-torque.xml
> > Log:
> > targetPackage is prefixed with "torque."
>
> Crazy...I'm really surprised I missed that. I've been defining only
> torque.targetPackage on a project I'm using the new build file on.
> Thanks for fixing it.
>
> So, I'm just trying to understand the Ant task part of Torque
> better...what constitutes a property being set via the Ant task's
> accessors or it being read via the build.properties?
>
> In particular, the targetPackage/targetDatabase accessors seem odd
> because they're defined in the build.properties but then explicitly put
> there in the initControlContext in the TorqueDataModelTask:
>
> context.put("targetDatabase", targetDatabase);
> context.put("targetPackage", targetPackage);
>
> And in TorqueDocumentationTask, the outputFormat variable that the task
> puts in the context in the initControlContext call is an exact replica
> of the documentationFormat/torque.doc.format property.
>
> I suppose you could say it divorces the templates from the properties,
> but then only a few properties are specifically defined via the Ant task
> accessors.
>
> Is this just a quirk? It's not that terribly important, but I've found
> myself wondering it several times since working on Torque and haven't
> figured it out yet.
>
> Thanks,
> Stephen
>
>
> --
> To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>