Re: [Hibernate] Default values for collection of elements
Max, some defaults are already different from hbm and we have more info I guess. I had that in mind, but the rule has to be pretty primitive: remove an extra s if in small letter and if the property size is more than 1 add an exception for children, bijoux, choux, genoux, cayoux, ... It should work for most English words, the majority of French ones (Max knows we have some interesting exceptions), but for other languages... Gavin King wrote: Can you de-pluralize the name of the association? I guess that is too hard... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Tuesday, 23 August 2005 4:39 PM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Default values for collection of elements I've finally implemented the most awaited features of annotations ever ( even before JDK 5 came out ;-) ): collection of primitive and core type. I'm wondering the appropriate defaults though: @Entity public class MyClass { @Id getId() {...} @OneToMany public SetString getElements() {...} create a MyClass_elements table having a MyClass_id column (default for EJB3) and an 'elt' column 'elt' is the default for HBM, but 'elements' might be a better one. Any opinion, better defaults? --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Default values for collection of elements
Then use element or value and be done with it ;) Or how about eltval? /max Max, some defaults are already different from hbm and we have more info I guess. I had that in mind, but the rule has to be pretty primitive: remove an extra s if in small letter and if the property size is more than 1 add an exception for children, bijoux, choux, genoux, cayoux, ... It should work for most English words, the majority of French ones (Max knows we have some interesting exceptions), but for other languages... Gavin King wrote: Can you de-pluralize the name of the association? I guess that is too hard... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Tuesday, 23 August 2005 4:39 PM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Default values for collection of elements I've finally implemented the most awaited features of annotations ever ( even before JDK 5 came out ;-) ): collection of primitive and core type. I'm wondering the appropriate defaults though: @Entity public class MyClass { @Id getId() {...} @OneToMany public SetString getElements() {...} create a MyClass_elements table having a MyClass_id column (default for EJB3) and an 'elt' column 'elt' is the default for HBM, but 'elements' might be a better one. Any opinion, better defaults? --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Default values for collection of elements
Can you de-pluralize the name of the association? I guess that is too hard... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Tuesday, 23 August 2005 4:39 PM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Default values for collection of elements I've finally implemented the most awaited features of annotations ever ( even before JDK 5 came out ;-) ): collection of primitive and core type. I'm wondering the appropriate defaults though: @Entity public class MyClass { @Id getId() {...} @OneToMany public SetString getElements() {...} create a MyClass_elements table having a MyClass_id column (default for EJB3) and an 'elt' column 'elt' is the default for HBM, but 'elements' might be a better one. Any opinion, better defaults? --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel