Fix null dicriminator unable to cast MarkerObject to ...

This commit is contained in:
Andrea Boriero 2021-06-28 15:07:11 +02:00
parent ce752c1428
commit 8895347867
180 changed files with 665 additions and 644 deletions

View File

@ -6,9 +6,6 @@
*/
package org.hibernate.userguide.envers;
import java.sql.Timestamp;
import java.time.LocalDateTime;
import java.time.ZoneOffset;
import java.util.Date;
import java.util.List;
import java.util.Map;
@ -26,11 +23,10 @@ import org.hibernate.envers.AuditReaderFactory;
import org.hibernate.envers.Audited;
import org.hibernate.envers.configuration.EnversSettings;
import org.hibernate.envers.query.AuditEntity;
import org.hibernate.envers.query.AuditQuery;
import org.hibernate.envers.strategy.ValidityAuditStrategy;
import org.hibernate.jpa.test.BaseEntityManagerFunctionalTestCase;
import org.hibernate.test.legacy.Custom;
import org.hibernate.orm.test.legacy.Custom;
import org.junit.Test;
import static org.hibernate.testing.transaction.TransactionUtil.doInJPA;

View File

@ -13,7 +13,7 @@
<property name="show_sql">true</property>
<mapping resource="org/hibernate/test/legacy/Simple.hbm.xml"/>
<class-cache
class="org.hibernate.test.legacy.Simple"
class="org.hibernate.orm.test.legacy.Simple"
region="Simple"
usage="read-write"/>
</session-factory>

View File

@ -27,11 +27,11 @@ import org.hibernate.jdbc.Work;
import org.hibernate.testing.RequiresDialect;
import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase;
import org.hibernate.test.legacy.Blobber;
import org.hibernate.test.legacy.Broken;
import org.hibernate.test.legacy.Fixed;
import org.hibernate.test.legacy.Simple;
import org.hibernate.test.legacy.Single;
import org.hibernate.orm.test.legacy.Blobber;
import org.hibernate.orm.test.legacy.Broken;
import org.hibernate.orm.test.legacy.Fixed;
import org.hibernate.orm.test.legacy.Simple;
import org.hibernate.orm.test.legacy.Single;
import org.junit.Test;
import static org.junit.Assert.assertEquals;

View File

@ -57,6 +57,7 @@ import org.hibernate.sql.ast.tree.from.TableGroup;
import org.hibernate.sql.ast.tree.predicate.ComparisonPredicate;
import org.hibernate.sql.ast.tree.predicate.InListPredicate;
import org.hibernate.sql.ast.tree.predicate.Junction;
import org.hibernate.sql.ast.tree.predicate.NegatedPredicate;
import org.hibernate.sql.ast.tree.predicate.NullnessPredicate;
import org.hibernate.sql.ast.tree.predicate.Predicate;
import org.hibernate.type.AssociationType;
@ -1018,13 +1019,21 @@ public class SingleTableEntityPersister extends AbstractEntityPersister {
}
return p;
}
final Object value = getDiscriminatorValue();
final boolean hasNotNullDiscriminator = value == NOT_NULL_DISCRIMINATOR;
final boolean hasNullDiscrininator = value == NULL_DISCRIMINATOR;
if ( hasNotNullDiscriminator || hasNullDiscrininator ) {
final NullnessPredicate nullnessPredicate = new NullnessPredicate( sqlExpression );
if ( hasNotNullDiscriminator ) {
return new NegatedPredicate( nullnessPredicate );
}
return nullnessPredicate;
}
return new ComparisonPredicate(
sqlExpression,
ComparisonOperator.EQUAL,
new QueryLiteral<>(
getDiscriminatorValue(),
discriminatorType
)
new QueryLiteral<>( value, discriminatorType )
);
}

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class A {
private Long id;

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.A" discriminator-value="0" lazy="true" table="TA">
<class name="org.hibernate.orm.test.legacy.A" discriminator-value="0" lazy="true" table="TA">
<id name = "id" column="identifier_column" unsaved-value = "null">
<generator class="increment"/>
</id>
@ -20,13 +20,13 @@
<column name="name" index="indx_a_name2"/>
</property>
<subclass name="org.hibernate.test.legacy.B" discriminator-value="-1" lazy="true">
<subclass name="org.hibernate.orm.test.legacy.B" discriminator-value="-1" lazy="true">
<property name="count" column="count_"/>
<join fetch="select" table="B2">
<key column="bid"/>
<property name="BName" not-null="true"/>
</join>
<subclass name="org.hibernate.test.legacy.C1" discriminator-value="null" lazy="true">
<subclass name="org.hibernate.orm.test.legacy.C1" discriminator-value="null" lazy="true">
<property name="address" column="c1"/>
<one-to-one name="d"/>
<join table="cmore" fetch="select">
@ -37,7 +37,7 @@
</subclass>
</class>
<class name="org.hibernate.test.legacy.D" discriminator-value="0" proxy="org.hibernate.test.legacy.D" table="TD">
<class name="org.hibernate.orm.test.legacy.D" discriminator-value="0" proxy="org.hibernate.orm.test.legacy.D" table="TD">
<id name = "id" unsaved-value = "null">
<generator class="assigned"/>
</id>
@ -54,7 +54,7 @@
</class>
<sql-query name="propertyResultDiscriminator">
<return alias="a" class="org.hibernate.test.legacy.A">
<return alias="a" class="org.hibernate.orm.test.legacy.A">
<return-discriminator column="clazz"/>
<return-property name="id" column="identifier_column"/>
<return-property name="name" column="name"/>

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<subclass name="org.hibernate.test.legacy.C2" discriminator-value="2" extends="org.hibernate.test.legacy.B" lazy="true">
<subclass name="org.hibernate.orm.test.legacy.C2" discriminator-value="2" extends="org.hibernate.orm.test.legacy.B" lazy="true">
<property name="address" column="c2"/>
<join table="c2more" fetch="select">
<key column="c2"/>

View File

@ -10,14 +10,14 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.A" discriminator-value="0" lazy="true" table="AP">
<class name="org.hibernate.orm.test.legacy.A" discriminator-value="0" lazy="true" table="AP">
<id name="id" column="identifier_column" unsaved-value = "null">
<generator class="increment"/>
</id>
<discriminator column="clazz_discriminata" type="integer" force="true" not-null="false"/>
<property name="name"/>
<many-to-one name="forward" class="org.hibernate.test.legacy.E" cascade="save-update" />
<subclass name="org.hibernate.test.legacy.B" discriminator-value="null" lazy="true">
<many-to-one name="forward" class="org.hibernate.orm.test.legacy.E" cascade="save-update" />
<subclass name="org.hibernate.orm.test.legacy.B" discriminator-value="null" lazy="true">
<property name="count" column="count_"/>
<map name="map" table="`map`">
@ -26,42 +26,42 @@
<element column="MAPVAL" type="int"/>
</map>
<subclass name="org.hibernate.test.legacy.C1" discriminator-value="1" lazy="true">
<subclass name="org.hibernate.orm.test.legacy.C1" discriminator-value="1" lazy="true">
<property name="address" column="c1"/>
<one-to-one name="d"/>
<many-to-one name="c2" column="c" class="org.hibernate.test.legacy.C2"/>
<many-to-one name="c2" column="c" class="org.hibernate.orm.test.legacy.C2"/>
<bag name="c2s" inverse="true" where="identifier_column is not null"> <!--where="clazz_discriminata=2"-->
<key column="c"/>
<one-to-many class="org.hibernate.test.legacy.C2"/>
<one-to-many class="org.hibernate.orm.test.legacy.C2"/>
</bag>
</subclass>
<subclass name="org.hibernate.test.legacy.C2" discriminator-value="2" lazy="true">
<subclass name="org.hibernate.orm.test.legacy.C2" discriminator-value="2" lazy="true">
<property name="address" column="c2"/>
<many-to-one name="c1" column="c" class="org.hibernate.test.legacy.C1"/>
<many-to-one name="c1" column="c" class="org.hibernate.orm.test.legacy.C1"/>
<bag name="c1s" inverse="true" > <!--where="clazz_discriminata=1"-->
<key column="c"/>
<one-to-many class="org.hibernate.test.legacy.C1"/>
<one-to-many class="org.hibernate.orm.test.legacy.C1"/>
</bag>
</subclass>
</subclass>
</class>
<class name="org.hibernate.test.legacy.D" discriminator-value="0" lazy="true" table="DP">
<class name="org.hibernate.orm.test.legacy.D" discriminator-value="0" lazy="true" table="DP">
<id name = "id" unsaved-value = "null">
<generator class="assigned"/>
</id>
<property name="amount"/>
</class>
<class name="org.hibernate.test.legacy.E" discriminator-value="0" lazy="true" table="EP">
<class name="org.hibernate.orm.test.legacy.E" discriminator-value="0" lazy="true" table="EP">
<id name = "id" unsaved-value = "null">
<generator class="increment"/>
</id>
<property name="amount"/>
<one-to-one name="reverse" class="org.hibernate.test.legacy.A" property-ref="forward" cascade="save-update"/>
<one-to-one name="reverse" class="org.hibernate.orm.test.legacy.A" property-ref="forward" cascade="save-update"/>
<set name="as" lazy="true">
<key column="e"/>
<one-to-many class="org.hibernate.test.legacy.A"/>
<one-to-many class="org.hibernate.orm.test.legacy.A"/>
</set>
</class>

View File

@ -0,0 +1,185 @@
/*
* Hibernate, Relational Persistence for Idiomatic Java
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.orm.test.legacy;
import java.util.Iterator;
import java.util.List;
import org.hibernate.Cache;
import org.hibernate.boot.model.naming.Identifier;
import org.hibernate.mapping.Index;
import org.hibernate.mapping.Table;
import org.hibernate.testing.orm.junit.DomainModel;
import org.hibernate.testing.orm.junit.SessionFactory;
import org.hibernate.testing.orm.junit.SessionFactoryScope;
import org.junit.jupiter.api.Test;
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.junit.jupiter.api.Assertions.assertNotNull;
import static org.junit.jupiter.api.Assertions.assertNull;
import static org.junit.jupiter.api.Assertions.assertTrue;
@DomainModel(
xmlMappings = {
"org/hibernate/orm/test/legacy/ABC.hbm.xml", "org/hibernate/orm/test/legacy/ABCExtends.hbm.xml"
}
)
@SessionFactory
public class ABCTest {
@Test
public void testFormulaAssociation(SessionFactoryScope scope) {
Long did = 12L;
scope.inTransaction(
session -> {
D d = new D( did );
session.save( d );
A a = new A();
a.setName( "a" );
session.save( a );
d.setReverse( a );
d.inverse = a;
}
);
scope.inTransaction(
session -> {
D d = session.get( D.class, did );
assertNotNull( d.getReverse() );
session.clear();
getCache( scope ).evictEntityData( D.class );
getCache( scope ).evictEntityData( A.class );
d = session.get( D.class, did );
assertNotNull( d.inverse );
assertThat( d.inverse.getName(), is( "a" ) );
session.clear();
getCache( scope ).evictEntityData( D.class );
getCache( scope ).evictEntityData( A.class );
assertThat(
session.createQuery( "from D d join d.reverse r join d.inverse i where i = r" )
.list().size(),
is( 1 )
);
}
);
}
@Test
public void testHigherLevelIndexDefinition(SessionFactoryScope scope) {
Table table = scope.getMetadataImplementor()
.getDatabase()
.getDefaultNamespace()
.locateTable( Identifier.toIdentifier( "TA" ) );
Iterator<Index> indexItr = table.getIndexIterator();
boolean found = false;
while ( indexItr.hasNext() ) {
final Index index = indexItr.next();
if ( "indx_a_name".equals( index.getName() ) ) {
found = true;
break;
}
}
assertTrue( found, "Unable to locate indx_a_name index" );
}
@Test
public void testSubclassing(SessionFactoryScope scope) {
C1 c = new C1();
scope.inTransaction(
session -> {
D d = new D();
d.setAmount( 213.34f );
c.setAddress( "foo bar" );
c.setCount( 23432 );
c.setName( "c1" );
c.setBName( "a funny name" );
c.setD( d );
session.save( c );
d.setId( c.getId() );
session.save( d );
assertThat( session.createQuery( "from C2 c where 1=1 or 1=1" ).list().size(), is( 0 ) );
}
);
getCache( scope ).evictEntityData( A.class );
scope.inTransaction(
session -> {
C1 c1 = (C1) session.get( A.class, c.getId() );
assertTrue(
c1.getAddress().equals( "foo bar" ) &&
( c1.getCount() == 23432 ) &&
c1.getName().equals( "c1" ) &&
c1.getD().getAmount() > 213.3f
);
assertThat( c1.getBName(), is( "a funny name" ) );
}
);
getCache( scope ).evictEntityData( A.class );
scope.inTransaction(
session -> {
C1 c1 = (C1) session.get( B.class, c.getId() );
assertTrue(
c1.getAddress().equals( "foo bar" ) &&
( c1.getCount() == 23432 ) &&
c1.getName().equals( "c1" ) &&
c1.getD().getAmount() > 213.3f
);
assertThat( c1.getBName(), is( "a funny name" ) );
}
);
scope.inTransaction(
session -> {
C1 c1 = session.load( C1.class, c.getId() );
assertTrue(
c1.getAddress().equals( "foo bar" ) &&
( c1.getCount() == 23432 ) &&
c1.getName().equals( "c1" ) &&
c1.getD().getAmount() > 213.3f
);
}
);
scope.inTransaction(
session -> {
List<C1> bs = session.createQuery( "from B" ).list();
for ( C1 b : bs ) {
session.delete( b );
session.delete( b.getD() );
}
}
);
}
@Test
public void testGetSave(SessionFactoryScope scope) {
scope.inTransaction(
session -> {
assertNull( session.get( D.class, 1L ) );
D d = new D();
d.setId( 1L );
session.save( d );
session.flush();
assertNotNull( session.get( D.class, 1L ) );
session.delete( d );
session.flush();
}
);
}
private Cache getCache(SessionFactoryScope scope) {
return scope.getSessionFactory().getCache();
}
}

View File

@ -6,7 +6,8 @@
*/
//$Id: Abstract.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.Set;
public abstract class Abstract extends Foo implements AbstractProxy {

View File

@ -4,14 +4,13 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public interface AbstractProxy extends FooProxy {
public void setAbstracts(java.util.Set arg0);
public java.util.Set getAbstracts();
public void setTime(java.sql.Time arg0);
public java.sql.Time getTime();
void setAbstracts(java.util.Set arg0);
java.util.Set getAbstracts();
void setTime(java.sql.Time arg0);
java.sql.Time getTime();
}

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Simple" table="SIMP">
<class name="org.hibernate.orm.test.legacy.Simple" table="SIMP">
<id name="id" type="long" column="id_">
<generator class="assigned"/>
</id>

View File

@ -4,7 +4,8 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.Collection;
/**

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.Map;

View File

@ -6,8 +6,7 @@
*/
//$Id: Bar.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class Bar extends Abstract implements BarProxy, Named {
private String barString;

View File

@ -6,18 +6,18 @@
*/
//$Id: BarProxy.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public interface BarProxy extends AbstractProxy {
public void setBaz(Baz arg0);
public Baz getBaz();
public void setBarComponent(FooComponent arg0);
public FooComponent getBarComponent();
void setBaz(Baz arg0);
Baz getBaz();
void setBarComponent(FooComponent arg0);
FooComponent getBarComponent();
//public void setBarString(String arg0);
public String getBarString();
public Object getObject();
public void setObject(Object o);
String getBarString();
Object getObject();
void setObject(Object o);
}

View File

@ -6,7 +6,7 @@
*/
//$Id: BasicNameable.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Baz"
<class name="org.hibernate.orm.test.legacy.Baz"
table="baz"
check="count_count > -666">
<id name="code" type="string">
@ -20,7 +20,7 @@
<property name="count" column="count_count"/>
<property name="name" column="name_b"/>
<!--property name="text" type="text" column="text_"/-->
<many-to-one name="foo" outer-join="true" class="org.hibernate.test.legacy.Foo"/>
<many-to-one name="foo" outer-join="true" class="org.hibernate.orm.test.legacy.Foo"/>
<list name="stringList" table="string_list" batch-size="12">
<key>
@ -40,20 +40,20 @@
<key>
<column name="baz_id" length="16"/>
</key>
<one-to-many class="org.hibernate.test.legacy.Foo"/>
<one-to-many class="org.hibernate.orm.test.legacy.Foo"/>
</set>
<array name="components" table="bazcomponents">
<key>
<column name="baz_id" length="16"/>
</key>
<index column="i"/>
<composite-element class="org.hibernate.test.legacy.FooComponent">
<composite-element class="org.hibernate.orm.test.legacy.FooComponent">
<parent name="baz"/>
<property name="name">
<column name="name" length="56"/>
</property>
<property name="count" column="count_"/>
<nested-composite-element name="subcomponent" class="org.hibernate.test.legacy.FooComponent">
<nested-composite-element name="subcomponent" class="org.hibernate.orm.test.legacy.FooComponent">
<property name="name" column="x_"/>
<property name="count" column="y_"/>
</nested-composite-element>
@ -76,52 +76,52 @@
<key>
<column name="baz_id" length="16"/>
</key>
<index-many-to-many column="foo_id" class="org.hibernate.test.legacy.Foo"/>
<many-to-many column="glarch_id" class="org.hibernate.test.legacy.Glarch"/>
<index-many-to-many column="foo_id" class="org.hibernate.orm.test.legacy.Foo"/>
<many-to-many column="glarch_id" class="org.hibernate.orm.test.legacy.Glarch"/>
</map>
<map name="fooComponentToFoo">
<!--cache-->
<key>
<column name="baz_id" length="16"/>
</key>
<composite-index class="org.hibernate.test.legacy.FooComponent">
<composite-index class="org.hibernate.orm.test.legacy.FooComponent">
<key-property name="name" length="32"/>
<key-property name="count" column="count_"/>
</composite-index>
<many-to-many column="foo_id" class="org.hibernate.test.legacy.Foo" outer-join="true"/>
<many-to-many column="foo_id" class="org.hibernate.orm.test.legacy.Foo" outer-join="true"/>
</map>
<map name="glarchToFoo">
<key>
<column name="gtf_baz_id" length="16"/>
</key>
<index-many-to-many column="gtf_foo_id" class="org.hibernate.test.legacy.Foo"/>
<one-to-many class="org.hibernate.test.legacy.Glarch"/>
<index-many-to-many column="gtf_foo_id" class="org.hibernate.orm.test.legacy.Foo"/>
<one-to-many class="org.hibernate.orm.test.legacy.Glarch"/>
</map>
<set name="stringSet" lazy="true" sort="org.hibernate.test.legacy.StringComparator" batch-size="12">
<set name="stringSet" lazy="true" sort="org.hibernate.orm.test.legacy.StringComparator" batch-size="12">
<!--<cache usage="read-write"/>-->
<key column="id_"/>
<element column="element" type="string" not-null="true" length="32"/>
</set>
<map name="stringDateMap" lazy="true" sort="org.hibernate.test.legacy.ReverseComparator">
<map name="stringDateMap" lazy="true" sort="org.hibernate.orm.test.legacy.ReverseComparator">
<key column="id_"/>
<index column="map_key" type="string" length="32"/>
<element column="map_value" type="date"/>
</map>
<array name="fooArray" table="FOO_ARRAY" element-class="org.hibernate.test.legacy.FooProxy" where="i&lt;8" check="i>=0">
<array name="fooArray" table="FOO_ARRAY" element-class="org.hibernate.orm.test.legacy.FooProxy" where="i&lt;8" check="i>=0">
<!--cache-->
<key column="id_"/>
<index column="i"/>
<many-to-many class="org.hibernate.test.legacy.Foo" fetch="select">
<many-to-many class="org.hibernate.orm.test.legacy.Foo" fetch="select">
<column name="foo" length="36"/>
</many-to-many>
</array>
<bag name="fooBag" lazy="true" table="baz_foo" cascade="all-delete-orphan" inverse="false">
<key column="baz"/>
<many-to-many class="org.hibernate.test.legacy.Foo" column="foo" outer-join="true"/>
<many-to-many class="org.hibernate.orm.test.legacy.Foo" column="foo" outer-join="true"/>
</bag>
<idbag name="idFooBag" lazy="true" table="baz_id_foo" cascade="all">
@ -129,7 +129,7 @@
<generator class="increment"/>
</collection-id>
<key column="baz"/>
<many-to-many class="org.hibernate.test.legacy.Foo" column="foo" outer-join="true"/>
<many-to-many class="org.hibernate.orm.test.legacy.Foo" column="foo" outer-join="true"/>
</idbag>
<idbag name="byteBag" lazy="true" table="baz_byte_bag">
@ -149,14 +149,14 @@
<list name="fees" lazy="true" cascade="all" check="bazind is null or (bazind>=0 and bazind&lt;10)">
<key column="bazid"/>
<index column="bazind"/>
<one-to-many class="org.hibernate.test.legacy.Fee"/>
<one-to-many class="org.hibernate.orm.test.legacy.Fee"/>
</list>
<list name="topComponents" table="topcomponents">
<!--cache-->
<key column="id_"/>
<index column="i"/>
<composite-element class="org.hibernate.test.legacy.FooComponent">
<composite-element class="org.hibernate.orm.test.legacy.FooComponent">
<property name="name"/>
<property name="count" column="count_"/>
</composite-element>
@ -164,12 +164,12 @@
<set name="topFoos">
<key column="idtopbar" />
<one-to-many class = "org.hibernate.test.legacy.Bar"/>
<one-to-many class = "org.hibernate.orm.test.legacy.Bar"/>
</set>
<set name="cascadingBars" cascade="all-delete-orphan">
<key column="idofbaz" />
<one-to-many class = "org.hibernate.test.legacy.Bar"/>
<one-to-many class = "org.hibernate.orm.test.legacy.Bar"/>
</set>
<map name="topGlarchez" outer-join="true">
@ -177,13 +177,13 @@
<index type="character">
<column name="mapkey" sql-type="char(1)"/>
</index>
<one-to-many class = "org.hibernate.test.legacy.Glarch"/>
<one-to-many class = "org.hibernate.orm.test.legacy.Glarch"/>
</map>
<set name="cached" sort="natural" table="cached_set">
<!--cache-->
<key column="baz"/>
<composite-element class="org.hibernate.test.legacy.CompositeElement">
<composite-element class="org.hibernate.orm.test.legacy.CompositeElement">
<property name="foo" not-null="true"/>
<property name="bar" not-null="true"/>
</composite-element>
@ -192,8 +192,8 @@
<map name="cachedMap" sort="natural" table="cached_map">
<!--cache-->
<key column="baz"/>
<index-many-to-many column="another_baz" class="org.hibernate.test.legacy.Baz"/>
<composite-element class="org.hibernate.test.legacy.CompositeElement">
<index-many-to-many column="another_baz" class="org.hibernate.orm.test.legacy.Baz"/>
<composite-element class="org.hibernate.orm.test.legacy.CompositeElement">
<property name="foo"/>
<property name="bar"/>
</composite-element>
@ -202,7 +202,7 @@
<map name="stringGlarchMap" where="baz_map_index &gt; 'a' and tha_key is not null" cascade="all">
<key column="baz_map_id"/>
<index column="baz_map_index" type="string"/>
<one-to-many class="org.hibernate.test.legacy.Glarch"/>
<one-to-many class="org.hibernate.orm.test.legacy.Glarch"/>
</map>
<map name="anyToAny" lazy="true">
@ -228,27 +228,27 @@
<bag name="bazez" lazy="true" order-by="name_b desc" cascade="all">
<key column="`baz-id`"/>
<one-to-many class="org.hibernate.test.legacy.Baz"/>
<one-to-many class="org.hibernate.orm.test.legacy.Baz"/>
</bag>
<set name="sortablez" sort="natural" cascade="all">
<key column="baz"/>
<one-to-many class="org.hibernate.test.legacy.Sortable"/>
<one-to-many class="org.hibernate.orm.test.legacy.Sortable"/>
</set>
<bag name="parts" lazy="true" cascade="save-update">
<key column="baz"/>
<one-to-many class="org.hibernate.test.legacy.Part"/>
<one-to-many class="org.hibernate.orm.test.legacy.Part"/>
</bag>
<bag name="moreParts" lazy="true" cascade="save-update">
<key column="baz"/>
<many-to-many column="part" class="org.hibernate.test.legacy.Part"/>
<many-to-many column="part" class="org.hibernate.orm.test.legacy.Part"/>
</bag>
<bag name="subs" inverse="true" cascade="all" access="field">
<key column="superBaz" on-delete="cascade"/>
<one-to-many class="org.hibernate.test.legacy.Baz"/>
<one-to-many class="org.hibernate.orm.test.legacy.Baz"/>
</bag>
<many-to-one name="superBaz" access="field"/>
@ -258,7 +258,7 @@
<property name="str" column="`str`"/>
<bag name="foos" cascade="all">
<key column="baz_compon_id"/>
<one-to-many class="org.hibernate.test.legacy.Foo"/>
<one-to-many class="org.hibernate.orm.test.legacy.Foo"/>
</bag>
<bag name="floats" table="baz_floats_bag">
<key column="baz_compon_id"/>
@ -269,20 +269,20 @@
</class>
<class name="org.hibernate.test.legacy.Sortable">
<class name="org.hibernate.orm.test.legacy.Sortable">
<id name="id">
<generator class="native"/>
</id>
<property name="name"/>
</class>
<class name="org.hibernate.test.legacy.Part" where="description like 'x%'">
<class name="org.hibernate.orm.test.legacy.Part" where="description like 'x%'">
<id name="id">
<generator class="native"/>
</id>
<discriminator column="clazz"/>
<property name="description"/>
<subclass name="org.hibernate.test.legacy.Part$SpecialPart"/>
<subclass name="org.hibernate.orm.test.legacy.Part$SpecialPart"/>
</class>

View File

@ -6,7 +6,8 @@
*/
//$Id: Baz.java 4688 2004-10-26 09:10:50Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Collection;

View File

@ -9,7 +9,7 @@
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Blobber" dynamic-update="true">
<class name="org.hibernate.orm.test.legacy.Blobber" dynamic-update="true">
<id name="id">
<generator class="increment"/>
</id>

View File

@ -4,7 +4,8 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.sql.Blob;
import java.sql.Clob;

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Broken" table="BROKE">
<class name="org.hibernate.orm.test.legacy.Broken" table="BROKE">
<!--id name="id" type="long" column="id_">
<generator class="increment"/>
</id-->
@ -19,7 +19,7 @@
<key-property name="otherId"/>
</composite-id>
<timestamp name="timestamp" column="`timestamp`"/>
<joined-subclass name="org.hibernate.test.legacy.Fixed" table="FIX">
<joined-subclass name="org.hibernate.orm.test.legacy.Fixed" table="FIX">
<key>
<column name="BROKE_ID"/>
<column name="OTHER_BROKE_ID"/>
@ -29,7 +29,7 @@
<column name="FIX_ID"/>
<column name="OTHER_FIX_ID"/>
</key>
<one-to-many class="org.hibernate.test.legacy.Broken"/>
<one-to-many class="org.hibernate.orm.test.legacy.Broken"/>
</set>
<property name="list" type="serializable"/>
</joined-subclass>

View File

@ -6,7 +6,8 @@
*/
//$Id: Broken.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.Date;

View File

@ -6,7 +6,8 @@
*/
//$Id: C1.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.ArrayList;
import java.util.Collection;

View File

@ -6,7 +6,8 @@
*/
//$Id: C2.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.ArrayList;
import java.util.Collection;

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Category"
<class name="org.hibernate.orm.test.legacy.Category"
table="category"
dynamic-update="true"
dynamic-insert="true">
@ -23,7 +23,7 @@
<!--cache-->
<key column="parent"/>
<index column="ord"/>
<one-to-many class="org.hibernate.test.legacy.Category"/>
<one-to-many class="org.hibernate.orm.test.legacy.Category"/>
</list>
<property name="name"/>
@ -31,25 +31,25 @@
</class>
<class name="org.hibernate.test.legacy.Assignable" table="`assign-able`">
<class name="org.hibernate.orm.test.legacy.Assignable" table="`assign-able`">
<id name="id">
<generator class="assigned"/>
</id>
<bag name="categories" inverse="true" cascade="all" lazy="true">
<key column="`assign-able-id`"/>
<one-to-many class="org.hibernate.test.legacy.Category"/>
<one-to-many class="org.hibernate.orm.test.legacy.Category"/>
</bag>
</class>
<sql-query name="namedsql">
<return alias="category" class="org.hibernate.test.legacy.Category"/>
<return alias="assignable" class="org.hibernate.test.legacy.Assignable"/>
<return alias="category" class="org.hibernate.orm.test.legacy.Category"/>
<return alias="assignable" class="org.hibernate.orm.test.legacy.Assignable"/>
select {category.*}, {assignable.*} from category {category}, "assign-able" {assignable}
</sql-query>
<sql-query name="nonaliasedsql">
<return alias="category" class="org.hibernate.test.legacy.Category">
<return alias="category" class="org.hibernate.orm.test.legacy.Category">
<return-property name="id" column="category_key_col"/>
<return-property name="name" column="name"/>
<return-property name="assignable" column="assignid"/>

View File

@ -6,7 +6,8 @@
*/
//$Id: Category.java 5686 2005-02-12 07:27:32Z steveebersole $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.ArrayList;
import java.util.List;

View File

@ -6,7 +6,7 @@
*/
//$Id: Child.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class Child {

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false" default-cascade="save-update">
<class name="org.hibernate.test.legacy.Circular" dynamic-update="true">
<class name="org.hibernate.orm.test.legacy.Circular" dynamic-update="true">
<id name="id" column="id_" length="64" unsaved-value="null">
<generator class="uuid"/>
</id>

View File

@ -6,8 +6,7 @@
*/
//$Id: Circular.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class Circular {

View File

@ -4,13 +4,13 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**
* @author hbm2java
*/
public class Company extends org.hibernate.test.legacy.Party {
public class Company extends org.hibernate.orm.test.legacy.Party {
java.lang.String id;
java.lang.String president;

View File

@ -6,7 +6,7 @@
*/
//$Id: Component.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -6,7 +6,8 @@
*/
//$Id: ComponentCollection.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.List;

View File

@ -6,7 +6,7 @@
*/
//$Id: ComponentNotNull.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -11,7 +11,7 @@
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.ComponentNotNullRoot"> <!-- discriminator-value="A"> -->
<class name="org.hibernate.orm.test.legacy.ComponentNotNullRoot"> <!-- discriminator-value="A"> -->
<id name="id" column="container_id">
<generator class="native" />
</id>
@ -31,7 +31,7 @@
<list name="components" lazy="true" table="CompNotNullRoot_Comps">
<key column = "container_id"/>
<index column = "list_index"/>
<composite-element class="org.hibernate.test.legacy.ComponentNotNullRoot$ContainerInnerClass">
<composite-element class="org.hibernate.orm.test.legacy.ComponentNotNullRoot$ContainerInnerClass">
<property name="name"/>
<property name="count" column="count_"/>
<many-to-one name="simple" not-null="true" cascade="save-update"/>
@ -43,12 +43,12 @@
<list name="componentsImplicit" lazy="true" table="CompNotNullRoot_CompsImpl">
<key column = "container_id"/>
<index column = "list_index3"/>
<composite-element class="org.hibernate.test.legacy.ComponentNotNullRoot$ContainerInnerClass">
<composite-element class="org.hibernate.orm.test.legacy.ComponentNotNullRoot$ContainerInnerClass">
<property name="name"/>
<property name="count" column="count_"/>
<many-to-one name="simple" cascade="save-update"/>
<many-to-one name="one" cascade="save-update"/>
<nested-composite-element name="nested" class="org.hibernate.test.legacy.ComponentNotNullRoot$ContainerInnerClass">
<nested-composite-element name="nested" class="org.hibernate.orm.test.legacy.ComponentNotNullRoot$ContainerInnerClass">
<property name="nestedproperty" not-null="true"/>
</nested-composite-element>
</composite-element>

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.List;

View File

@ -9,14 +9,14 @@
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Componentizable">
<class name="org.hibernate.orm.test.legacy.Componentizable">
<id name="id">
<generator class="native"/>
</id>
<property name="nickName"/>
<component name="component" access="property" class="org.hibernate.test.legacy.Component">
<component name="component" access="property" class="org.hibernate.orm.test.legacy.Component">
<property name="name"/>
<component name="subComponent" class="org.hibernate.test.legacy.SubComponent">
<component name="subComponent" class="org.hibernate.orm.test.legacy.SubComponent">
<property name="subName"/>
<property name="subName1"/>
</component>
@ -24,7 +24,7 @@
</class>
<sql-query name="queryComponentWithOtherColumn">
<return class="org.hibernate.test.legacy.Componentizable">
<return class="org.hibernate.orm.test.legacy.Componentizable">
<return-property name="nickName" column="n2"/>
<return-property name="component.subComponent.subName">
<return-column name="otherSubName"/>

View File

@ -6,7 +6,7 @@
*/
//$Id: Componentizable.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -6,7 +6,8 @@
*/
//$Id: CompositeElement.java 6844 2005-05-21 14:22:16Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
public class CompositeElement implements Comparable, Serializable {

View File

@ -6,7 +6,7 @@
~ See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
-->
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping package="org.hibernate.test.legacy">
<hibernate-mapping package="org.hibernate.orm.test.legacy">
<class name="CompositeIdId">
<composite-id>
<key-property name="user"/>

View File

@ -9,7 +9,8 @@
* Created on 20-Dec-2004
*
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
/**

View File

@ -6,7 +6,8 @@
*/
//$Id: Contained.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.ArrayList;
import java.util.Collection;

View File

@ -12,28 +12,28 @@
<hibernate-mapping default-lazy="false" auto-import="false">
<import class="org.hibernate.test.legacy.Container" rename="ContainerX"/>
<import class="org.hibernate.test.legacy.Contained"/>
<import class="org.hibernate.orm.test.legacy.Container" rename="ContainerX"/>
<import class="org.hibernate.orm.test.legacy.Contained"/>
<import class="java.lang.Object" rename="Universe"/>
<class name="org.hibernate.test.legacy.Container" proxy="org.hibernate.test.legacy.Container">
<class name="org.hibernate.orm.test.legacy.Container" proxy="org.hibernate.orm.test.legacy.Container">
<id name="id" column="container_id" unsaved-value="0">
<generator class="native" />
</id>
<list name="oneToMany" lazy="true">
<key column = "container_id1"/>
<index column = "list_index"/>
<one-to-many class="org.hibernate.test.legacy.Simple"/>
<one-to-many class="org.hibernate.orm.test.legacy.Simple"/>
</list>
<list name="manyToMany" lazy="true">
<key column = "container_id2"/>
<index column = "list_index"/>
<many-to-many class="org.hibernate.test.legacy.Simple"/>
<many-to-many class="org.hibernate.orm.test.legacy.Simple"/>
</list>
<list name="components" lazy="true">
<key column = "container_id"/>
<index column = "list_index"/>
<composite-element class="org.hibernate.test.legacy.Container$ContainerInnerClass">
<composite-element class="org.hibernate.orm.test.legacy.Container$ContainerInnerClass">
<property name="name"/>
<property name="count" column="count_"/>
<many-to-one name="simple"/>
@ -43,7 +43,7 @@
</list>
<set name="composites" lazy="true">
<key column = "container_id"/>
<composite-element class="org.hibernate.test.legacy.Container$ContainerInnerClass">
<composite-element class="org.hibernate.orm.test.legacy.Container$ContainerInnerClass">
<property name="name"/>
<many-to-one name="simple"/>
<many-to-one name="one"/>
@ -52,7 +52,7 @@
</set>
<bag name="cascades" cascade="all" table="abcd">
<key column="container_id"/>
<composite-element class="org.hibernate.test.legacy.Container$ContainerInnerClass">
<composite-element class="org.hibernate.orm.test.legacy.Container$ContainerInnerClass">
<property name="name"/>
<many-to-one name="simple" cascade="all"/>
<many-to-one name="one" cascade="all" not-null="true"/>
@ -61,17 +61,17 @@
</bag>
<bag name="bag" inverse="true" cascade="save-update" table="CCBAG">
<key column="container_id"/>
<many-to-many column="contained_id" class="org.hibernate.test.legacy.Contained" outer-join="true"/>
<many-to-many column="contained_id" class="org.hibernate.orm.test.legacy.Contained" outer-join="true"/>
</bag>
<bag name="lazyBag" inverse="true" lazy="true" table="LCCBAG" cascade="save-update">
<!--cache usage="read-write"-->
<key column="container_id"/>
<many-to-many column="contained_id" class="org.hibernate.test.legacy.Contained"/>
<many-to-many column="contained_id" class="org.hibernate.orm.test.legacy.Contained"/>
</bag>
<map name="ternaryMap">
<key column="container_id"/>
<index column="idx" type="string" length="32"/>
<composite-element class="org.hibernate.test.legacy.Container$Ternary">
<composite-element class="org.hibernate.orm.test.legacy.Container$Ternary">
<property name="name"/>
<many-to-one name="foo"/>
<many-to-one name="glarch"/>
@ -79,7 +79,7 @@
</map>
<set name="ternarySet">
<key column="container_id"/>
<composite-element class="org.hibernate.test.legacy.Container$Ternary">
<composite-element class="org.hibernate.orm.test.legacy.Container$Ternary">
<property name="name" not-null="true"/>
<many-to-one name="foo" not-null="true"/>
<many-to-one name="glarch" not-null="true"/>
@ -87,17 +87,17 @@
</set>
</class>
<class name="org.hibernate.test.legacy.Contained" proxy="org.hibernate.test.legacy.Contained">
<class name="org.hibernate.orm.test.legacy.Contained" proxy="org.hibernate.orm.test.legacy.Contained">
<id name="id" column="container_id" unsaved-value="0">
<generator class="native" />
</id>
<bag name="bag" table="CCBAG">
<key column="contained_id"/>
<many-to-many column="container_id" class="org.hibernate.test.legacy.Container" outer-join="false"/>
<many-to-many column="container_id" class="org.hibernate.orm.test.legacy.Container" outer-join="false"/>
</bag>
<bag name="lazyBag" lazy="true" table="LCCBAG">
<key column="contained_id"/>
<many-to-many column="container_id" class="org.hibernate.test.legacy.Container"/>
<many-to-many column="container_id" class="org.hibernate.orm.test.legacy.Container"/>
</bag>
</class>

View File

@ -6,7 +6,8 @@
*/
//$Id: Container.java 6844 2005-05-21 14:22:16Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Custom" persister="org.hibernate.test.legacy.CustomPersister">
<class name="org.hibernate.orm.test.legacy.Custom" persister="org.hibernate.orm.test.legacy.CustomPersister">
<id type="string" name="id" column="id_" length="64" unsaved-value="null" access="field">
<generator class="uuid.hex"/>
</id>

View File

@ -6,9 +6,7 @@
*/
//$Id: Custom.java 7275 2005-06-22 18:58:16Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class Custom implements Cloneable {
String id;

View File

@ -4,10 +4,9 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.Collection;
import java.util.Collections;
import java.util.Comparator;
import java.util.Hashtable;

View File

@ -8,7 +8,7 @@
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false" package="org.hibernate.test.legacy">
<hibernate-mapping default-lazy="false" package="org.hibernate.orm.test.legacy">
<class name="Role" table="`Role`">
<id name="id" type="long">
@ -99,7 +99,7 @@
<joined-subclass name="Medication">
<key column="interventionid"/>
<many-to-one name="prescribedDrug" class="org.hibernate.test.legacy.Drug"/>
<many-to-one name="prescribedDrug" class="org.hibernate.orm.test.legacy.Drug"/>
<sql-insert>insert into /** put weird comments here */ Medication (prescribedDrug, interventionid) values (?, ?)</sql-insert>
</joined-subclass>

View File

@ -6,7 +6,7 @@
*/
//$Id: D.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class D {

View File

@ -6,7 +6,8 @@
*/
//$Id: Detail.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;

View File

@ -6,9 +6,7 @@
*/
//$Id: Down.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**
* @author Gavin King

View File

@ -4,13 +4,12 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**
* @author hbm2java
*/
public class Drug extends org.hibernate.test.legacy.Resource {
public class Drug extends org.hibernate.orm.test.legacy.Resource {
java.lang.String id;

View File

@ -6,7 +6,8 @@
*/
//$Id: E.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.Set;
public class E {

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false"
default-cascade="save-update"
package="org.hibernate.test.legacy">
package="org.hibernate.orm.test.legacy">
<class name="Eye" lazy="true">
<id name="id" unsaved-value="0">

View File

@ -6,7 +6,8 @@
*/
//$Id: Eye.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.HashSet;
import java.util.Set;

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Fee" table="`the fees`">
<class name="org.hibernate.orm.test.legacy.Fee" table="`the fees`">
<id type="string" name="key" column="id_" length="64" unsaved-value="null">
<generator class="uuid"/>
</id>

View File

@ -6,7 +6,8 @@
*/
//$Id: Fee.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.Set;

View File

@ -6,7 +6,8 @@
*/
//$Id: Fixed.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;

View File

@ -10,8 +10,8 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Fo" table="foes">
<composite-id name="id" class="org.hibernate.test.legacy.FumCompositeID">
<class name="org.hibernate.orm.test.legacy.Fo" table="foes">
<composite-id name="id" class="org.hibernate.orm.test.legacy.FumCompositeID">
<key-property name="string">
<column name="string_" length="20"/>
</key-property>

View File

@ -6,7 +6,7 @@
*/
//$Id: Fo.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
public final class Fo {

View File

@ -6,7 +6,7 @@
*/
//$Id: Foo.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.sql.Timestamp;
import java.util.Calendar;

View File

@ -8,7 +8,7 @@
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false" package="org.hibernate.test.legacy">
<hibernate-mapping default-lazy="false" package="org.hibernate.orm.test.legacy">
<import class="Result"/>
<import class="Named"/>
@ -70,7 +70,7 @@
</property>
<property name="byte" column="byte_"/>
<property name="yesno" type="yes_no"/>
<property name="blob" type="org.hibernate.test.legacy.Foo$Struct" column="blobb_"/>
<property name="blob" type="org.hibernate.orm.test.legacy.Foo$Struct" column="blobb_"/>
<property name="nullBlob" type="serializable"/>
<property name="binary" column="bin_"/>
<property name="theLocale" access="field" column="`localeayzabc123`"/>
@ -85,7 +85,7 @@
<many-to-one name="glarch"
column="g__"
cascade="all"
class="org.hibernate.test.legacy.Glarch"
class="org.hibernate.orm.test.legacy.Glarch"
lazy="proxy"
outer-join="true"/>
<property name="null" column="cmpnt_null_"/>
@ -122,7 +122,7 @@
<join table="foo_dep_table">
<key column="fooid"/>
<many-to-one name="dependent"
class="org.hibernate.test.legacy.Fee"
class="org.hibernate.orm.test.legacy.Fee"
cascade="all"
not-null="true"/>
</join>

View File

@ -6,7 +6,7 @@
*/
//$Id: FooComponent.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.Date;

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public interface FooProxy {

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Fum" dynamic-update="true">
<class name="org.hibernate.orm.test.legacy.Fum" dynamic-update="true">
<!--cache-->
<composite-id name="id" unsaved-value="any">
<meta attribute="fum">fum</meta>
@ -32,7 +32,7 @@
<column name="fr_string_" length="10"/>
<column name="fr_short_"/>
</key>
<one-to-many class="org.hibernate.test.legacy.Fum"/>
<one-to-many class="org.hibernate.orm.test.legacy.Fum"/>
</set>
<array name="quxArray">
<key>
@ -40,7 +40,7 @@
<column name="fum_sho_"/>
</key>
<index column="i"/>
<one-to-many class="org.hibernate.test.legacy.Qux"/>
<one-to-many class="org.hibernate.orm.test.legacy.Qux"/>
</array>
<property name="dupe"
column="short_"
@ -55,7 +55,7 @@
<column name="fum_sho_"/>
</key>
<index column="fummapindex" type="string"/>
<one-to-many class="org.hibernate.test.legacy.Fum"/>
<one-to-many class="org.hibernate.orm.test.legacy.Fum"/>
</map>
<map name="stringmap" outer-join="true">
<key>

View File

@ -6,7 +6,7 @@
*/
//$Id: Fum.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.sql.SQLException;
import java.util.Calendar;

View File

@ -6,7 +6,7 @@
*/
//$Id: FumCompositeID.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Fumm">
<class name="org.hibernate.orm.test.legacy.Fumm">
<composite-id name="id">
<key-property name="string">
<column name="string_" length="10"/>

View File

@ -6,7 +6,7 @@
*/
//$Id: Fumm.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.Locale;
public class Fumm {

View File

@ -8,7 +8,7 @@
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false" package="org.hibernate.test.legacy">
<hibernate-mapping default-lazy="false" package="org.hibernate.orm.test.legacy">
<class name="Glarch"
table="`glarchez`"
@ -50,7 +50,7 @@
<array name="proxyArray" element-class="GlarchProxy">
<key column="array_key"/>
<index column="array_indecks"/>
<one-to-many class="org.hibernate.test.legacy.Glarch"/>
<one-to-many class="org.hibernate.orm.test.legacy.Glarch"/>
</array>
<set name="proxySet">
<key column="set_key"/>

View File

@ -6,7 +6,7 @@
*/
//$Id: Glarch.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.HashMap;
import java.util.List;

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.List;
import java.util.Map;
import java.util.Set;

View File

@ -9,7 +9,7 @@
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Holder">
<class name="org.hibernate.orm.test.legacy.Holder">
<id name="id" column="id_" type="string" length="32" unsaved-value="null">
<generator class="uuid.hex"/>
</id>
@ -17,16 +17,16 @@
<list name="ones">
<key column="holder"/>
<index column="i"/>
<one-to-many class="org.hibernate.test.legacy.One"/>
<one-to-many class="org.hibernate.orm.test.legacy.One"/>
</list>
<array name="fooArray">
<key column="holder1"/>
<index column="j1"/>
<one-to-many class="org.hibernate.test.legacy.Foo"/>
<one-to-many class="org.hibernate.orm.test.legacy.Foo"/>
</array>
<set name="foos">
<key column="holder2"/>
<one-to-many class="org.hibernate.test.legacy.Foo"/>
<one-to-many class="org.hibernate.orm.test.legacy.Foo"/>
</set>
<many-to-one name="otherHolder" property-ref="name" cascade="all"/>
</class>

View File

@ -6,7 +6,7 @@
*/
//$Id: Holder.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.List;
import java.util.Set;

View File

@ -6,7 +6,7 @@
*/
//$Id: I.java 7203 2005-06-19 02:01:05Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -9,7 +9,7 @@
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false"
package="org.hibernate.test.legacy"
package="org.hibernate.orm.test.legacy"
default-access="field">
<class name="I" discriminator-value="0">

View File

@ -9,7 +9,7 @@
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false"
package="org.hibernate.test.legacy"
package="org.hibernate.orm.test.legacy"
default-access="field">
<class name="I">

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Immutable" table="immut" mutable="false">
<class name="org.hibernate.orm.test.legacy.Immutable" table="immut" mutable="false">
<!--cache-->
<id name="id" column="id_" length="64">
<generator class="uuid"/>

View File

@ -6,7 +6,7 @@
*/
//$Id: Immutable.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class Immutable {

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.List;

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
/**

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -6,7 +6,7 @@
*/
//$Id: J.java 7203 2005-06-19 02:01:05Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -6,7 +6,7 @@
*/
//$Id: Jay.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -6,7 +6,7 @@
*/
//$Id: K.java 7203 2005-06-19 02:01:05Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.Set;
/**

View File

@ -10,7 +10,7 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Location">
<class name="org.hibernate.orm.test.legacy.Location">
<composite-id>
<key-property name="streetNumber"/>
<key-property name="streetName" length="20"/>

View File

@ -6,7 +6,7 @@
*/
//$Id: Location.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
import java.util.Locale;

View File

@ -6,7 +6,7 @@
*/
//$Id: Lower.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.List;
import java.util.Set;

View File

@ -12,7 +12,7 @@
<hibernate-mapping default-lazy="false">
<class
name="org.hibernate.test.legacy.MainObject"
name="org.hibernate.orm.test.legacy.MainObject"
table="mainobject"
dynamic-update="false"
dynamic-insert="false"
@ -31,7 +31,7 @@
<one-to-one
name="obj2"
class="org.hibernate.test.legacy.Object2"
class="org.hibernate.orm.test.legacy.Object2"
cascade="all"
outer-join="auto"
constrained="false"

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**

View File

@ -11,12 +11,12 @@
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Many" table="many">
<class name="org.hibernate.orm.test.legacy.Many" table="many">
<id name="key" column="many_key">
<generator class="native" />
</id>
<property name="x"/>
<many-to-one name="one" column="one_key" class="org.hibernate.test.legacy.One"/>
<many-to-one name="one" column="one_key" class="org.hibernate.orm.test.legacy.One"/>
</class>
</hibernate-mapping>

View File

@ -6,7 +6,7 @@
*/
//$Id: Many.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
public class Many {

View File

@ -4,22 +4,22 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
/**
* @author hbm2java
*/
public class Medication extends org.hibernate.test.legacy.Intervention {
public class Medication extends org.hibernate.orm.test.legacy.Intervention {
org.hibernate.test.legacy.Drug prescribedDrug;
org.hibernate.orm.test.legacy.Drug prescribedDrug;
org.hibernate.test.legacy.Drug getPrescribedDrug() {
org.hibernate.orm.test.legacy.Drug getPrescribedDrug() {
return prescribedDrug;
}
void setPrescribedDrug(org.hibernate.test.legacy.Drug newValue) {
void setPrescribedDrug(org.hibernate.orm.test.legacy.Drug newValue) {
prescribedDrug = newValue;
}

View File

@ -11,7 +11,7 @@
<hibernate-mapping default-lazy="false">
<class name="org.hibernate.test.legacy.Inner" table="CID_IN">
<class name="org.hibernate.orm.test.legacy.Inner" table="CID_IN">
<composite-id name="id">
<key-property name="akey" type="string" length="10" column="AKEY"/>
<key-property name="bkey" type="string" length="10" column="BKEY"/>
@ -22,7 +22,7 @@
<column length="10" name="AKEY"/>
<column length="10" name="BKEY"/>
</key>
<one-to-many class="org.hibernate.test.legacy.Middle"/>
<one-to-many class="org.hibernate.orm.test.legacy.Middle"/>
</bag>
<many-to-one name="backOut">
<column name="BO_AKEY"/>
@ -33,7 +33,7 @@
</many-to-one>
</class>
<class name="org.hibernate.test.legacy.Middle" table="CID_MID">
<class name="org.hibernate.orm.test.legacy.Middle" table="CID_MID">
<composite-id name="id">
<key-many-to-one name="sup">
<column length="10" name="AKEY"/>
@ -45,7 +45,7 @@
<property column="BLA" length="10" name="bla" not-null="true" type="string"/>
</class>
<class name="org.hibernate.test.legacy.Outer" table="CID_OUT">
<class name="org.hibernate.orm.test.legacy.Outer" table="CID_OUT">
<composite-id name="id">
<key-many-to-one name="root">
<column length="10" name="AKEY"/>

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
/**

View File

@ -4,7 +4,7 @@
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.io.Serializable;
/**

View File

@ -6,7 +6,7 @@
*/
//$Id: Mono.java 4599 2004-09-26 05:18:27Z oneovthafew $
package org.hibernate.test.legacy;
package org.hibernate.orm.test.legacy;
import java.util.Set;

Some files were not shown because too many files have changed in this diff Show More