package ${entity.getPackageName()};

import java.util.*;

import org.asyrinx.brownie.core.util.Captionable;

#foreach ($importFqn in ${entity.getImports()})
import ${importFqn};
#end

/** 
 * ${entity.getName()} [ ${entity.getLabel()} ]
#if ($addTimeStamp)
 * generated by joey-gen on $now
#end
 * @hibernate.class table="${entity.getOriginal().getName()}"
 */
public class ${entity.Name} extends ${entityBasePrefix}${entity.Name}${entityBaseSuffix} {

$generator.parse("om/entity/entity_constructor.vm", "")
	

#if( ${entity.getCaptionProperty()} )
#set( $captionProp = ${entity.getCaptionProperty()} )
	/**
	 * @see org.asyrinx.brownie.core.util.Captionable#getCaption()
	 */
	public String getCaption() {
#set( $getterInvoke = "get${stringUtils.capitalize( $captionProp.getName() )}()" )
#if( ${captionProp.getType().getName()} == "String" )		
		return ${getterInvoke};
#else	
		return String.valueOf(${getterInvoke});
#end	
	}
#end	

}
