Search in sources :

Example 31 with IValue

use of org.jboss.tools.hibernate.runtime.spi.IValue in project jbosstools-hibernate by jbosstools.

the class ServiceImplTest method testNewSet.

@Test
public void testNewSet() {
    IPersistentClass persistentClass = service.newRootClass();
    IValue set = service.newSet(persistentClass);
    Assert.assertNotNull(set);
    Object target = ((IFacade) set).getTarget();
    Assert.assertNotNull(target);
    Assert.assertTrue(target instanceof Set);
}
Also used : IValue(org.jboss.tools.hibernate.runtime.spi.IValue) Set(org.hibernate.mapping.Set) IFacade(org.jboss.tools.hibernate.runtime.common.IFacade) IPersistentClass(org.jboss.tools.hibernate.runtime.spi.IPersistentClass) Test(org.junit.Test)

Example 32 with IValue

use of org.jboss.tools.hibernate.runtime.spi.IValue in project jbosstools-hibernate by jbosstools.

the class ServiceImplTest method testNewOneToOne.

@Test
public void testNewOneToOne() {
    IPersistentClass persistentClass = service.newRootClass();
    IValue oneToOne = service.newOneToOne(persistentClass);
    Assert.assertNotNull(oneToOne);
    Object target = ((IFacade) oneToOne).getTarget();
    Assert.assertNotNull(target);
    Assert.assertTrue(target instanceof OneToOne);
}
Also used : OneToOne(org.hibernate.mapping.OneToOne) IValue(org.jboss.tools.hibernate.runtime.spi.IValue) IFacade(org.jboss.tools.hibernate.runtime.common.IFacade) IPersistentClass(org.jboss.tools.hibernate.runtime.spi.IPersistentClass) Test(org.junit.Test)

Example 33 with IValue

use of org.jboss.tools.hibernate.runtime.spi.IValue in project jbosstools-hibernate by jbosstools.

the class ServiceImplTest method testNewOneToMany.

@Test
public void testNewOneToMany() {
    IPersistentClass persistentClass = service.newRootClass();
    IValue oneToMany = service.newOneToMany(persistentClass);
    Assert.assertNotNull(oneToMany);
    Object target = ((IFacade) oneToMany).getTarget();
    Assert.assertNotNull(target);
    Assert.assertTrue(target instanceof OneToMany);
}
Also used : IValue(org.jboss.tools.hibernate.runtime.spi.IValue) IFacade(org.jboss.tools.hibernate.runtime.common.IFacade) OneToMany(org.hibernate.mapping.OneToMany) IPersistentClass(org.jboss.tools.hibernate.runtime.spi.IPersistentClass) Test(org.junit.Test)

Example 34 with IValue

use of org.jboss.tools.hibernate.runtime.spi.IValue in project jbosstools-hibernate by jbosstools.

the class ServiceImplTest method testNewPrimitiveArray.

@Test
public void testNewPrimitiveArray() {
    IPersistentClass persistentClass = service.newRootClass();
    IValue primitiveArray = service.newPrimitiveArray(persistentClass);
    Assert.assertNotNull(primitiveArray);
    Object target = ((IFacade) primitiveArray).getTarget();
    Assert.assertNotNull(target);
    Assert.assertTrue(target instanceof PrimitiveArray);
}
Also used : IValue(org.jboss.tools.hibernate.runtime.spi.IValue) PrimitiveArray(org.hibernate.mapping.PrimitiveArray) IFacade(org.jboss.tools.hibernate.runtime.common.IFacade) IPersistentClass(org.jboss.tools.hibernate.runtime.spi.IPersistentClass) Test(org.junit.Test)

Example 35 with IValue

use of org.jboss.tools.hibernate.runtime.spi.IValue in project jbosstools-hibernate by jbosstools.

the class ServiceImplTest method testSimpleValue.

@Test
public void testSimpleValue() {
    IValue simpleValue = service.newSimpleValue();
    Assert.assertNotNull(simpleValue);
    Object target = ((IFacade) simpleValue).getTarget();
    Assert.assertNotNull(target);
    Assert.assertTrue(target instanceof SimpleValue);
}
Also used : IValue(org.jboss.tools.hibernate.runtime.spi.IValue) IFacade(org.jboss.tools.hibernate.runtime.common.IFacade) SimpleValue(org.hibernate.mapping.SimpleValue) Test(org.junit.Test)

Aggregations

IValue (org.jboss.tools.hibernate.runtime.spi.IValue)144 Test (org.junit.Test)105 SimpleValue (org.hibernate.mapping.SimpleValue)68 IPersistentClass (org.jboss.tools.hibernate.runtime.spi.IPersistentClass)59 IFacade (org.jboss.tools.hibernate.runtime.common.IFacade)40 Bag (org.hibernate.mapping.Bag)20 Set (org.hibernate.mapping.Set)20 IProperty (org.jboss.tools.hibernate.runtime.spi.IProperty)20 ITable (org.jboss.tools.hibernate.runtime.spi.ITable)17 IdentifierBag (org.hibernate.mapping.IdentifierBag)16 KeyValue (org.hibernate.mapping.KeyValue)16 RootClass (org.hibernate.mapping.RootClass)16 Value (org.hibernate.mapping.Value)16 IConfiguration (org.jboss.tools.hibernate.runtime.spi.IConfiguration)13 Collection (org.hibernate.mapping.Collection)8 Component (org.hibernate.mapping.Component)8 List (org.hibernate.mapping.List)8 PersistentClass (org.hibernate.mapping.PersistentClass)8 PrimitiveArray (org.hibernate.mapping.PrimitiveArray)8 Table (org.hibernate.mapping.Table)8