FileDocCategorySizeDatePackage
Any.javaAPI DocHibernate 3.2.51572Tue Dec 07 02:59:56 GMT 2004org.hibernate.mapping

Any

public class Any extends SimpleValue
A Hibernate "any" type (ie. polymorphic association to one-of-several tables).
author
Gavin King

Fields Summary
private String
identifierTypeName
private String
metaTypeName
private Map
metaValues
Constructors Summary
public Any(Table table)


	   
		super(table);
	
Methods Summary
public java.lang.Objectaccept(ValueVisitor visitor)

		return visitor.accept(this);
	
public java.lang.StringgetIdentifierType()

		return identifierTypeName;
	
public java.lang.StringgetMetaType()

		return metaTypeName;
	
public java.util.MapgetMetaValues()

		return metaValues;
	
public org.hibernate.type.TypegetType()

		return new AnyType(
			metaValues==null ?
				TypeFactory.heuristicType(metaTypeName) :
				new MetaType( metaValues, TypeFactory.heuristicType(metaTypeName) ),
				TypeFactory.heuristicType(identifierTypeName)
		);
	
public voidsetIdentifierType(java.lang.String identifierType)

		this.identifierTypeName = identifierType;
	
public voidsetMetaType(java.lang.String type)

		metaTypeName = type;
	
public voidsetMetaValues(java.util.Map metaValues)

		this.metaValues = metaValues;
	
public voidsetTypeByReflection(java.lang.String propertyClass, java.lang.String propertyName)

public voidsetTypeUsingReflection(java.lang.String className, java.lang.String propertyName)