From: Michael D. <mik...@us...> - 2004-08-23 02:12:04
|
Update of /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24731 Modified Files: Foo.cs FooBar.hbm.xml Fum.cs Fum.hbm.xml Master.cs MasterDetail.hbm.xml Simple.hbm.xml Log Message: Modified classes and mappings to test the access="field" and the various field naming strategies. Index: Simple.hbm.xml =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel/Simple.hbm.xml,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** Simple.hbm.xml 19 Jul 2004 03:02:33 -0000 1.6 --- Simple.hbm.xml 23 Aug 2004 02:11:53 -0000 1.7 *************** *** 10,14 **** <property name="Count" column="count_" not-null="true" unique="true"/> <property name="Date" column="date_"/> ! <many-to-one name="Other"/> </class> --- 10,14 ---- <property name="Count" column="count_" not-null="true" unique="true"/> <property name="Date" column="date_"/> ! <many-to-one name="Other" access="field.camelcase"/> </class> Index: FooBar.hbm.xml =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel/FooBar.hbm.xml,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** FooBar.hbm.xml 21 Aug 2004 16:40:42 -0000 1.13 --- FooBar.hbm.xml 23 Aug 2004 02:11:53 -0000 1.14 *************** *** 73,81 **** <property name="Status" column="`status_@###`" type="NHibernate.DomainModel.FooStatus, NHibernate.DomainModel"/> <property name="Binary" column="bin_"/> ! <property name="Locale" column="`localeayzabc123!@#$`" type="locale"/> <property name="Formula" formula="1/2 * int_"/> ! <property name="Custom" type="NHibernate.DomainModel.DoubleStringType, NHibernate.DomainModel"> <column name="first_name" length="66"/> <column name="surname" length="66"/> --- 73,81 ---- <property name="Status" column="`status_@###`" type="NHibernate.DomainModel.FooStatus, NHibernate.DomainModel"/> <property name="Binary" column="bin_"/> ! <property name="Locale" column="`localeayzabc123!@#$`" access="field.camelcase-underscore" type="locale"/> <property name="Formula" formula="1/2 * int_"/> ! <property name="Custom" type="NHibernate.DomainModel.DoubleStringType, NHibernate.DomainModel" access="field.camelcase"> <column name="first_name" length="66"/> <column name="surname" length="66"/> *************** *** 135,138 **** --- 135,139 ---- class="NHibernate.DomainModel.Fee, NHibernate.DomainModel" outer-join="false" + access="field.camelcase-underscore" /> </component> Index: MasterDetail.hbm.xml =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel/MasterDetail.hbm.xml,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** MasterDetail.hbm.xml 28 Jul 2004 03:53:19 -0000 1.3 --- MasterDetail.hbm.xml 23 Aug 2004 02:11:53 -0000 1.4 *************** *** 16,22 **** <!--TODO: make sure this type has an equiv .net type--> <version ! name="Stamp" type="Timestamp" column="ts_" /> --- 16,23 ---- <!--TODO: make sure this type has an equiv .net type--> <version ! name="stamp" type="Timestamp" column="ts_" + access="field" /> Index: Fum.cs =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel/Fum.cs,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Fum.cs 18 Jun 2004 13:48:11 -0000 1.5 --- Fum.cs 23 Aug 2004 02:11:53 -0000 1.6 *************** *** 11,15 **** private Qux[] _quxArray; private IDictionary _friends; // <set> mapping ! private DateTime _lastUpdated; public Fum() --- 11,15 ---- private Qux[] _quxArray; private IDictionary _friends; // <set> mapping ! private DateTime m_LastUpdated; public Fum() *************** *** 24,28 **** // when executing the Sql. H203 uses the CalendarType which we don't have so // I am using DateTime instead... ! _lastUpdated = DateTime.Now; FumCompositeID fid = new FumCompositeID(); --- 24,28 ---- // when executing the Sql. H203 uses the CalendarType which we don't have so // I am using DateTime instead... ! m_LastUpdated = DateTime.Now; FumCompositeID fid = new FumCompositeID(); *************** *** 152,160 **** get { ! return _lastUpdated; } set { ! _lastUpdated = value; } } --- 152,160 ---- get { ! return m_LastUpdated; } set { ! m_LastUpdated = value; } } Index: Master.cs =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel/Master.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Master.cs 29 Jul 2004 13:05:28 -0000 1.3 --- Master.cs 23 Aug 2004 02:11:53 -0000 1.4 *************** *** 21,25 **** // to set it right now because it checks to see if value==null -> since this // is a struct it is not null... ! private DateTime _stamp = DateTime.Now; // private BigDecimal bigDecimal = new BigDecimal("1234.123"); TODO: how to do in .net private int _x; --- 21,25 ---- // to set it right now because it checks to see if value==null -> since this // is a struct it is not null... ! private DateTime stamp = DateTime.Now; // private BigDecimal bigDecimal = new BigDecimal("1234.123"); TODO: how to do in .net private int _x; *************** *** 91,100 **** } - public DateTime Stamp - { - get { return _stamp; } - set { _stamp = value; } - } - public int X { --- 91,94 ---- Index: Foo.cs =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel/Foo.cs,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** Foo.cs 6 Jul 2004 04:27:36 -0000 1.10 --- Foo.cs 23 Aug 2004 02:11:53 -0000 1.11 *************** *** 70,74 **** private System.Globalization.CultureInfo _locale; private String _formula; ! private string[] _custom; private int _version; private FooProxy _foo; --- 70,74 ---- private System.Globalization.CultureInfo _locale; private String _formula; ! private string[] custom; private int _version; private FooProxy _foo; *************** *** 315,320 **** public string[] Custom { ! get { return _custom; } ! set { _custom = value; } } --- 315,320 ---- public string[] Custom { ! get { return custom; } ! set { custom = value; } } *************** *** 396,400 **** _status=FooStatus.ON; _binary = System.Text.Encoding.ASCII.GetBytes( _string + "yada yada yada" ); ! _custom = new string[] { "foo", "bar" --- 396,400 ---- _status=FooStatus.ON; _binary = System.Text.Encoding.ASCII.GetBytes( _string + "yada yada yada" ); ! custom = new string[] { "foo", "bar" *************** *** 466,470 **** && ( _key.Equals(other.Key) ) && ( _locale.Equals(other.Locale) ) ! && ( ( _custom == other.Custom ) || ( _custom[0].Equals(other.Custom[0]) && _custom[1].Equals(other.Custom[1]) ) ) ; } --- 466,470 ---- && ( _key.Equals(other.Key) ) && ( _locale.Equals(other.Locale) ) ! && ( ( custom == other.Custom ) || ( custom[0].Equals(other.Custom[0]) && custom[1].Equals(other.Custom[1]) ) ) ; } Index: Fum.hbm.xml =================================================================== RCS file: /cvsroot/nhibernate/nhibernate/src/NHibernate.DomainModel/Fum.hbm.xml,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Fum.hbm.xml 18 Jun 2004 13:48:11 -0000 1.5 --- Fum.hbm.xml 23 Aug 2004 02:11:53 -0000 1.6 *************** *** 27,31 **** <version name="LastUpdated" ! type="DateTime" /> --- 27,32 ---- <version name="LastUpdated" ! type="DateTime" ! access="field.pascalcase-m-underscore" /> |