• 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
  • Tim Cooke
  • Devaka Cooray
  • Ron McLeod
  • Jeanne Boyarsky
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Martijn Verburg
  • Frits Walraven
  • Himai Minh

RMI-IIOP and Local Home & Component Interfaces

 
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have been reviewing the spec and the Head First book, and it is clear that the remote component interface and home methods in the remote home interface have to be RMI-IIOP compliant.
This restriction is not noted in the corresponding local component and local home interface sections. It is logical to assume that the restriction does not apply to local interfaces (since objects won't be passed over the wire) but I just wanted to be sure.
 
Cowgirl and Author
Posts: 1589
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You're absolutely right -- local interfaces don't have that restriction because for local interfaces, plain old Java language rules apply... and everything is passed by value/copy (i.e. a copy of the bits in the variable are passed... either a copy of a primitive, or a copy of a reference).
Which is perhaps one of the most significant issues related to local vs. Remote interfaces... with local interfaces, a business method is passed a reference to an existing object on the heap, and thus the business method might *change* the object in some way. With Remote interfaces, the business method is passed its very own *copy* of the whole object itself, and any changes made to the object don't affect the original object that was passed.
Good question. Never hurts to be certain about your assumptions, no matter how obvious they might seem. There are no dumb questions
(except the ones you're too afraid to ask)
Cheers,
Kathy
 
a wee bit from the empire
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic