• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Rob Spoor
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Henry Wong
  • Liutauras Vilda
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Tim Holloway
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Mikalai Zaikin
  • Piet Souris

Compile time Error(EJB)

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am using weblogic 5.1,I got a problem "cannot
resolve Symbol" when i compile HomeInterface i get
this error,
my Remote Interface is
import java.rmi.RemoteException;
import java.rmi.Remote;
import javax.ejb.*;
public interface Demo extends EJBObject, Remote {
public String demoSelect() throws RemoteException;
}
and my HomeInterface is
import javax.ejb.*;
import java.rmi.Remote;
import java.rmi.RemoteException;
import java.util.*;
public interface DemoHome extends EJBHome {
public Demo create() throws CreateException,
RemoteException;
}

ERROR:cannot resolve symbol Demo
Note:Remote interface is compling fine
I already run setenv.Is it anything wrong on setEnv then how can i overcome this
PLs help me
Thanks
 
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why are you extending Remote when EJBObject already does that?
Kyle
 
Ranch Hand
Posts: 393
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi kuralmani Elango,
I think we need to go back to basics of Java class/interface can't extend more than one class/interface.
And as Kyle said,RemoteObject is already extends Remote interface,so there is no need to extend Remote Interface.Just refer EJB API.you will come to know.
Cheers....
James
 
Ranch Hand
Posts: 2713
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by james edwin:
I think we need to go back to basics of Java class/interface can't extend more than one class/interface.


An interface can extend any number of interfaces. A class can implement any number of interfaces. A class however can only extend from a single class.
As Kyle said, this doesn't mean that Demo should extend Remote.
 
Kyle Brown
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by kuralmani Elango:
Hi,
I am using weblogic 5.1,I got a problem "cannot
resolve Symbol" when i compile HomeInterface i get
this error,
my Remote Interface is
import java.rmi.RemoteException;
import java.rmi.Remote;
import javax.ejb.*;
public interface Demo extends EJBObject, Remote {
public String demoSelect() throws RemoteException;
}
and my HomeInterface is
import javax.ejb.*;
import java.rmi.Remote;
import java.rmi.RemoteException;
import java.util.*;
public interface DemoHome extends EJBHome {
public Demo create() throws CreateException,
RemoteException;
}

ERROR:cannot resolve symbol Demo
Note:Remote interface is compling fine
I already run setenv.Is it anything wrong on setEnv then how can i overcome this
PLs help me
Thanks


There is no package declaration either. Try putting these both in the SAME package and compiling them together and see if that helps.
Kyle
 
Ranch Hand
Posts: 227
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ouch James, that hurts... I could point you to some good COBOL forums if you'd like! <smile>
[ March 01, 2003: Message edited by: Dana Hanna ]
reply
    Bookmark Topic Watch Topic
  • New Topic