Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

question about RemoteDataFactory!!!!!

 
hwlm H
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,Mark:
pls help me!!!
i have a DataAccess which is the remote interface contains all public mothods of Data ,
i use RemoteDataImpl implements the interface
and extends UnicastRemoteObject , so RemoteDataImpl is the remote object. On the server side , I have a class named RemoteDataFactory.I
bind the factory to the registry and have that factory issue unique connection objects--RemoteDataImpl,but the error occour: because the RemoteDataFactory also extends UnicastRemoteObject and not implement remote interface, when i use "rmic",
the errer is "java.rmi.server.RemoteServer is not a valid remote implementation: has no
remote interfaces", so i can not get the stub for RemoteDataFactory!!!
pls help me ,thanks.
 
Vikas Sood
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
make ur RemoteFactory class also implement a remote interface.Any class extending UnicastRemoteObject should also implement a Remote interface so as to be used remotely.
VikasSood
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"hwlm_ch"-
Welcome to the JavaRanch! Please adjust your displayed name to meet the
JavaRanch Naming Policy.
You can change it
here.
Thanks! and welcome to the JavaRanch!
Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic