Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

return type of ItemBean() Constructor

Posted on 2004-09-15
4
Medium Priority
?
168 Views
Last Modified: 2013-11-24
Hi,

I am working on the TUSC tutorial
"Tutorial for building J2EE Applications using JBOSS and ECLIPSE "

In chapter 6 I am trying to generate an CMP EJB, but after Creation using the Lomboz EJB Creation Wizard if got an error because of the return type of my ItemBean Constructor:


   public ItemBean() throws javax.ejb.CreateException {
        return null;
    }

Of course this can´t work because void can´t return something. But other classes are depending on this ItemBean class and I can´t just take away the return statement.
I also couldn´t find any information about the correct use of this Constructor.

Any suggestions?

Thx, Stefan
0
Comment
Question by:Scotchman
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 6

Expert Comment

by:expertmb
ID: 12065259
>> ItemBean Constructor:
constructor's doesnot have return type.
0
 
LVL 6

Accepted Solution

by:
expertmb earned 200 total points
ID: 12065283
remove/comment the below statement and then compile
   public ItemBean() throws javax.ejb.CreateException {
      //   return null;
    }
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
This video teaches viewers about errors in exception handling.
Suggested Courses

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question