Java Examples for org.hibernate.mapping.PersistentClassVisitor

The following java examples will help you to understand the usage of org.hibernate.mapping.PersistentClassVisitor. These source code samples are taken from different open source projects.

Example 1
Project: hibernate-tools-master  File: Cfg2HbmTool.java View source code
public boolean needsTable(PersistentClass clazz) {
    Boolean accept = (Boolean) clazz.accept(new PersistentClassVisitor() {

        public Object accept(Subclass subclass) {
            return Boolean.FALSE;
        }

        public Object accept(JoinedSubclass subclass) {
            return Boolean.TRUE;
        }

        public Object accept(SingleTableSubclass subclass) {
            return Boolean.FALSE;
        }

        public Object accept(UnionSubclass subclass) {
            return Boolean.TRUE;
        }

        public Object accept(RootClass class1) {
            return Boolean.TRUE;
        }
    });
    return accept.booleanValue();
}