You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by Andy Kriger <an...@verizon.net> on 2002/12/24 17:02:56 UTC
base classes using object wrappers instead of primitives?
How hard would it be for me to modify Torque to get it to generate base
classes that use object wrappers instead of primitives (e.g. Integer instead
of int)?
Would this require massive changes (in the generation of peers and base
classes)?
Could I do this simply by editing the Object.vm template?
If so, is there a way to tell the Torque ant target to use my custom
template instead of the default?
That's a lot of questions dancing around the same topic. The motivation for
this is that Jini Entries require fields to be public objects. I'd like to
be able to generate these objects using the same Torque system (since it
worked so well for plain-old classes). If anyone more familiar with Torque
than I has any ideas on the simplest way to approach this, please let me
know. I'd be happy to contribute anything I come up with back to the
project.
thx
andy
RE: base classes using object wrappers instead of primitives?
Posted by Andy Kriger <an...@verizon.net>.
Is there a way to get the jdbc task to set this up for me? Or do I have to
post-process the schema file?
-----Original Message-----
From: Eric Emminger [mailto:eric@ericemminger.com]
Sent: Tuesday, 24 December, 2002 14:28
To: Turbine Torque Users List
Subject: Re: base classes using object wrappers instead of primitives?
Andy
> How hard would it be for me to modify Torque to get it to generate base
> classes that use object wrappers instead of primitives (e.g. Integer
instead
> of int)?
In your database schema, use javaType="object" in the column element.
Note that both primary and foreign keys will need this property.
Merry Christmas!
Eric
--
Eric Emminger
eric@ericemminger.com
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
Re: base classes using object wrappers instead of primitives?
Posted by Eric Emminger <er...@ericemminger.com>.
Andy
> How hard would it be for me to modify Torque to get it to generate base
> classes that use object wrappers instead of primitives (e.g. Integer instead
> of int)?
In your database schema, use javaType="object" in the column element.
Note that both primary and foreign keys will need this property.
Merry Christmas!
Eric
--
Eric Emminger
eric@ericemminger.com