-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 
Author Message
 Post subject: e-book java persistence with hibernate
PostPosted: Wed Jan 24, 2007 10:55 am 
Newbie

Joined: Wed Jan 24, 2007 10:45 am
Posts: 2
e-book, page 83

1 error : cannot find symbol "MessageHandler"

package hello;

import javax.ejb.Stateless;
import javax.persistence.*;
import java.util.List;

@Stateless
public class MessageHandlerBean implements MessageHandler

Thank you,
Douglas V[/url]


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 24, 2007 11:39 am 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
You need to write the interface MessageHandler. It's in the same package. It's also shown on the same book page at the top.

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 24, 2007 1:13 pm 
Newbie

Joined: Wed Jan 24, 2007 10:45 am
Posts: 2
christian wrote:
You need to write the interface MessageHandler. It's in the same package. It's also shown on the same book page at the top.


I have done that,

using the JCreator editor
windows xp

src/hello/
Message.java
MessageHandler.java
MessageHandlerBean.java


Thank you,
Douglas V


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 24, 2007 1:23 pm 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
Download the source code from http://caveatemptor.hibernate.org/ and compare it to what you did. The available source compiles and runs fine standalone. If you get a "cannot find symbol" message, your directory/project/classpath setup in your IDE is very likely wrong.

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Feb 10, 2007 4:01 am 
Regular
Regular

Joined: Tue Jan 03, 2006 9:20 am
Posts: 74
Just because the source file is in that directory doesn't necessarilly mean it's got the proper package name (not all IDEs enforce a source tree where all sources are placed in a directory structure matching their package structure, and neither does the compiler).

I'd doublecheck that first of all.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.