RE: [Hibernate] CodeGenerator Tool

2003-02-13 Thread Aapo Laakkonen
> The CodeGenerator tool generates private setters/getters. > Is there a way to force it to generate public setters/ > getters? Grap the latest cvs version or modify BasicRenderer. --- This SF.NET email is sponsored by: FREE SSL Guide from Th

[Hibernate] CodeGenerator Tool

2003-02-13 Thread Gordon
The CodeGenerator tool generates private setters/getters. Is there a way to force it to generate public setters/getters? Gordon --- This SF.NET email is sponsored by: FREE SSL Guide from Thawte are you planning your Web Server Security? Click

Re: RE: [Hibernate] CodeGenerator in Hibernate2

2003-01-31 Thread Gavin . King
TECTED] cc: eforge.net Subject: Re: RE: [Hibernate] CodeGenerat

RE: RE: [Hibernate] CodeGenerator in Hibernate2

2003-01-30 Thread Aapo Laakkonen
> I agree 100%, and I'm puzzled by this. > I posted about that in the Forum on SF, > asking the same questions. Ok... it's strange... Hibernate uses several metatags to do this. Defaults SUCK big time if you ask me. And it also uses the same function for both (getFieldScope). I attached fixed Basi

Re: RE: [Hibernate] CodeGenerator in Hibernate2

2003-01-30 Thread otisg
I agree 100%, and I'm puzzled by this. I posted about that in the Forum on SF, asking the same questions. Cf. http://sourceforge.net/forum/forum.php?thread_id=802051&forum_id=128638 No answers yetam I missing something here? Thanks, Otis On Thu, 30 Jan 2003, Aapo Laakkonen ([EMAIL P

RE: [Hibernate] CodeGenerator in Hibernate2

2003-01-30 Thread Aapo Laakkonen
Ok, I see that the BasicRenderer seems to want some parameter and it defaults to private, which is insane, I think (should default to public). --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something

[Hibernate] CodeGenerator in Hibernate2

2003-01-30 Thread Aapo Laakkonen
Why does CodeGenerator in Hibernate2 generate "private" getters and setters? --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com _

Re: [Hibernate] Codegenerator of the future?

2003-01-10 Thread Max Rydahl Andersen
Thursday, January 09, 2003 11:27 PM Subject: [Hibernate] Codegenerator of the future? > Will the Codegenerator of the future > (http://hibernate.bluemars.net/52.html#17) replace the current > ReverseGenerator? What I mean is that I have used the ReverseGenerator to > create a Tabl

[Hibernate] Codegenerator of the future?

2003-01-09 Thread Raible, Matt
Will the Codegenerator of the future (http://hibernate.bluemars.net/52.html#17) replace the current ReverseGenerator? What I mean is that I have used the ReverseGenerator to create a TableName.java class and it's accompanying TableName.hbm.xml. This works great and I applaud you all on making thi

RE: [Hibernate] CodeGenerator

2003-01-01 Thread Gavin King
> Its it the actual field, the getX() or the setX() that should > be modified ? (The same actually goes for the "description" tag...) I meant the get/set pair. Fields should always be private. perhaps it makes more sense to have getter-scope and setter-scope. > How about having "description-get

Re: [Hibernate] CodeGenerator

2003-01-01 Thread Max Rydahl Andersen
> > > > > > JavaDoc comment for getBar() > > > > java.lang.Object > > > > . > > But this one ? Isn't this a bit "cloudy" > If I understand this correctly you want that if "java-type" > is provided the codegenerator should use that type instead of > the t

RE: [Hibernate] CodeGenerator

2002-12-31 Thread Gavin King
> > > > > > JavaDoc comment for getBar() > > > > java.lang.Object > > > > . > > But this one ? Isn't this a bit "cloudy" > If I understand this correctly you want that if "java-type" > is provided the codegenerator should use that type instead of > t

Re: [Hibernate] CodeGenerator

2002-12-30 Thread Max Rydahl Andersen
> > Thus, I'll suggest (and also make a patch as I get to it) that it > > should be optional to have the dependency on commons-lang. > Optimal, we > > could generate a bare-boned toString method based on the > > attributes/properties know to the metadata. > > > > On second thought - I'll add an opt

RE: [Hibernate] CodeGenerator

2002-12-30 Thread Gavin King
> > >The generated classes now have a dependency upon > commons-lang, which > > >doesn't bother me in the slightest, but other people may > have another > > >opinion. > > > > Yes - me for one :) I would like to keep the generated code > as simple > > as possible :) (but at the same time I li

RE: [Hibernate] CodeGenerator

2002-12-30 Thread Gavin King
gt; From: [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED] On > > Behalf Of Gavin King > > Sent: Sunday, December 29, 2002 4:09 AM > > To: [EMAIL PROTECTED] > > Subject: [Hibernate] CodeGenerator > > > > > > > > Hi everyone, > > > > I sp

Re: [Hibernate] CodeGenerator

2002-12-29 Thread Juozas Baliuka
equals() and hashCode() can be implemented using this definition : for all persistent objects a, b : a.equals(a) === true a.equals(b) ==> b.equals(a) a.equals(b) ==> a.hashCode() = b.hashCode() a is persistent ==> a.getId() != null a.equals(b)

Re: [Hibernate] CodeGenerator

2002-12-29 Thread Max Rydahl Andersen
> >The generated classes now have a dependency upon > >commons-lang, which doesn't bother me in the > >slightest, but other people may have another > >opinion. > > Yes - me for one :) I would like to keep the generated code > as simple as possible :) (but at the same time I like to broaden > the u

Re: [Hibernate] CodeGenerator

2002-12-29 Thread Max Rydahl Andersen
guidelines written here: (which is what commons-lang has done) http://java.sun.com/docs/books/effective/chapters.html (Read Chapter 3) /max - Original Message - From: "Matt Raible" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, December 29, 2002 4:47 PM S

RE: [Hibernate] CodeGenerator

2002-12-29 Thread Matt Raible
> > This is more or less what commons-lang's reflectionToString > does (which is what Gavin's patch will make the CodeGenerator do now) > > But what about your hashCode ? > > /max > I'm looking for advice on how to implement an equals() and hashCode() method in my base class. Any suggestion

Re: [Hibernate] CodeGenerator

2002-12-29 Thread Max Rydahl Andersen
> Is it recommended that all hibernate persistent classes implement > equals() and hashcode()? It is always recommende to implement equals and hashCode for any class that you would consider putting into java collections or other mechanisms that tries to identity and/or sort themso yes, it is

RE: [Hibernate] CodeGenerator

2002-12-29 Thread Matt Raible
att > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On > Behalf Of Gavin King > Sent: Sunday, December 29, 2002 4:09 AM > To: [EMAIL PROTECTED] > Subject: [Hibernate] CodeGenerator > > > > Hi everyone, > > I spent some t

Re: [Hibernate] CodeGenerator

2002-12-29 Thread Max Rydahl Andersen
>The generated classes now have a dependency upon >commons-lang, which doesn't bother me in the >slightest, but other people may have another >opinion. Yes - me for one :) I would like to keep the generated code as simple as possible :) (but at the same time I like to broaden the usage of commons

RE: [Hibernate] CodeGenerator

2002-11-08 Thread Aapo Laakkonen
> Yeah that would make more sense. Do you wanna produce a patch? (Do we > need to worry about backward compatibility on this?) Maybe I could look this after I get some sleep, :-). Quick search to source code gave me an idea. The feature I'm after can easily be patched at the bottom of Basic Rende

Re: [Hibernate] CodeGenerator

2002-11-08 Thread Gavin King
konen" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, November 08, 2002 12:54 AM Subject: [Hibernate] CodeGenerator > Is it possible to modify CodeGenerator tool so that when I have property > type set to "true_false" or "yes_no" and name set to &qu

[Hibernate] CodeGenerator

2002-11-08 Thread Aapo Laakkonen
Is it possible to modify CodeGenerator tool so that when I have property type set to "true_false" or "yes_no" and name set to "something" eg.: to generate something like this: public boolean isSomething() { return this.something; } public void setSomething(boolean something

Re: [Hibernate] CodeGenerator bug

2002-11-02 Thread Gavin King
Thanks Max :) - Original Message - From: "Max Rydahl Andersen" <[EMAIL PROTECTED]> To: "Gavin King" <[EMAIL PROTECTED]> Sent: Sunday, November 03, 2002 1:13 AM Subject: Re: [Hibernate] CodeGenerator bug > > > The codegenerator assumes

Re: [Hibernate] CodeGenerator bug

2002-11-01 Thread Gavin King
> The codegenerator assumes there are at least ONE attribute on each > persistent class, and in this case it sees none > because of the above mentioned "error". Theoretically Hibernate can persist a class with no properties ... CodeGenerator should handle the *possibility* at least. > I can easi

Re: [Hibernate] CodeGenerator bug

2002-10-31 Thread Max Rydahl Andersen
d (except if we add a new feature to the codegenerator to insert af default java type for properties without a type?) /max - Original Message - From: "Gavin King" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, October 31, 2002 6:37 PM Subject: [Hiberna

Re: [Hibernate] CodeGenerator bug

2002-10-31 Thread Max Rydahl Andersen
Yes - it was the problem about creation of the minimal constructor in the codegen. Which hbm.xml are you running it on ? /max - Original Message - From: "Gavin King" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, October 31, 2002 6:37 PM Subject: [Hi