[jbosstools-issues] [JBoss JIRA] Commented: (JBIDE-1768) hbm2java: error generating collection of components

Carsten Hoehne (JIRA) jira-events at lists.jboss.org
Sun Feb 10 05:09:05 EST 2008


    [ http://jira.jboss.com/jira/browse/JBIDE-1768?page=comments#action_12399023 ] 
            
Carsten Hoehne commented on JBIDE-1768:
---------------------------------------

for convinience here is the exception:
2008-02-10 10:53:35,312 ERROR Worker-3 freemarker.runtime - 

Expression pojo.generateManyToOneAnnotation is undefined on line 11, column 3 in pojo/Ejb3PropertyGetAnnotation.ftl.
The problematic instruction:
----------
==> ${pojo.generateManyToOneAnnotation(property)} [on line 11, column 1 in pojo/Ejb3PropertyGetAnnotation.ftl]
 in include "Ejb3PropertyGetAnnotation.ftl" [on line 1, column 1 in pojo/GetPropertyAnnotation.ftl]
 in include "GetPropertyAnnotation.ftl" [on line 9, column 5 in pojo/PojoPropertyAccessors.ftl]
 in include "PojoPropertyAccessors.ftl" [on line 12, column 1 in pojo/Pojo.ftl]
----------

Java backtrace for programmers:
----------
freemarker.core.InvalidReferenceException: Expression pojo.generateManyToOneAnnotation is undefined on line 11, column 3 in pojo/Ejb3PropertyGetAnnotation.ftl.
	at freemarker.core.TemplateObject.assertNonNull(TemplateObject.java:124)
	at freemarker.core.TemplateObject.invalidTypeException(TemplateObject.java:134)
	at freemarker.core.MethodCall._getAsTemplateModel(MethodCall.java:114)
	at freemarker.core.Expression.getAsTemplateModel(Expression.java:89)
	at freemarker.core.Expression.getStringValue(Expression.java:93)
	at freemarker.core.DollarVariable.accept(DollarVariable.java:76)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.MixedContent.accept(MixedContent.java:92)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.IfBlock.accept(IfBlock.java:82)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.MixedContent.accept(MixedContent.java:92)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:79)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.Environment.include(Environment.java:1375)
	at freemarker.core.Include.accept(Include.java:155)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.Environment.include(Environment.java:1375)
	at freemarker.core.Include.accept(Include.java:155)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.MixedContent.accept(MixedContent.java:92)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:79)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:160)
	at freemarker.core.Environment.visit(Environment.java:351)
	at freemarker.core.IteratorBlock.accept(IteratorBlock.java:95)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.MixedContent.accept(MixedContent.java:92)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.Environment.include(Environment.java:1375)
	at freemarker.core.Include.accept(Include.java:155)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.MixedContent.accept(MixedContent.java:92)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.IfBlock.accept(IfBlock.java:82)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.MixedContent.accept(MixedContent.java:92)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.Environment.visit(Environment.java:233)
	at freemarker.core.BlockAssignment.accept(BlockAssignment.java:83)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.MixedContent.accept(MixedContent.java:92)
	at freemarker.core.Environment.visit(Environment.java:196)
	at freemarker.core.Environment.process(Environment.java:176)
	at freemarker.template.Template.process(Template.java:232)
	at org.hibernate.tool.hbm2x.TemplateHelper.processTemplate(TemplateHelper.java:251)
	at org.hibernate.tool.hbm2x.TemplateProducer.produceToString(TemplateProducer.java:67)
	at org.hibernate.tool.hbm2x.TemplateProducer.produce(TemplateProducer.java:28)
	at org.hibernate.tool.hbm2x.TemplateProducer.produce(TemplateProducer.java:97)
	at org.hibernate.tool.hbm2x.GenericExporter.exportPOJO(GenericExporter.java:146)
	at org.hibernate.tool.hbm2x.GenericExporter.exportComponent(GenericExporter.java:131)
	at org.hibernate.tool.hbm2x.GenericExporter$3.process(GenericExporter.java:61)
	at org.hibernate.tool.hbm2x.GenericExporter.doStart(GenericExporter.java:126)
	at org.hibernate.tool.hbm2x.AbstractExporter.start(AbstractExporter.java:95)
	at org.hibernate.eclipse.launch.CodeGenerationLaunchDelegate$1.execute(CodeGenerationLaunchDelegate.java:256)
	at org.hibernate.console.execution.DefaultExecutionContext.execute(DefaultExecutionContext.java:65)
	at org.hibernate.console.ConsoleConfiguration.execute(ConsoleConfiguration.java:88)
	at org.hibernate.eclipse.launch.CodeGenerationLaunchDelegate.runExporters(CodeGenerationLaunchDelegate.java:226)
	at org.hibernate.eclipse.launch.CodeGenerationLaunchDelegate.launch(CodeGenerationLaunchDelegate.java:134)
	at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:766)
	at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:608)
	at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:899)
	at org.eclipse.debug.internal.ui.DebugUIPlugin$7.run(DebugUIPlugin.java:1102)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)



> hbm2java: error generating collection of components
> ---------------------------------------------------
>
>                 Key: JBIDE-1768
>                 URL: http://jira.jboss.com/jira/browse/JBIDE-1768
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: Hibernate
>    Affects Versions: 2.0.0.GA
>            Reporter: Carsten Hoehne
>         Attachments: Sample.hbm.xml, Sample2Well.hbm.xml
>
>
> Java code with annotations should be generated from a mapping file. This file contains a collection of components. Then an exception is thrown. See forum reference.
> The files will be attached. 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jbosstools-issues mailing list