FileDocCategorySizeDatePackage
SingleTableSubclass.javaAPI DocHibernate 3.2.51279Wed Jun 22 12:02:26 BST 2005org.hibernate.mapping

SingleTableSubclass

public class SingleTableSubclass extends Subclass
author
Gavin King

Fields Summary
Constructors Summary
public SingleTableSubclass(PersistentClass superclass)

		super(superclass);
	
Methods Summary
public java.lang.Objectaccept(PersistentClassVisitor mv)

		return mv.accept(this);
	
protected java.util.IteratorgetDiscriminatorColumnIterator()

		if ( isDiscriminatorInsertable() && !getDiscriminator().hasFormula() ) {
			return getDiscriminator().getColumnIterator();
		}
		else {
			return super.getDiscriminatorColumnIterator();
		}
	
protected java.util.IteratorgetNonDuplicatedPropertyIterator()

		return new JoinedIterator( 
				getSuperclass().getUnjoinedPropertyIterator(),
				getUnjoinedPropertyIterator()
		);
	
public voidvalidate(org.hibernate.engine.Mapping mapping)

        if(getDiscriminator()==null) {
            throw new MappingException("No discriminator found for " + getEntityName() + ". Discriminator is needed when 'single-table-per-hierarchy' is used and a class has subclasses");
        }
        super.validate(mapping);