Solved

java and win16

Posted on 1997-05-23
6
334 Views
Last Modified: 2012-08-13
How can java and win16 communicate with each other?
0
Comment
Question by:Balaji052397
[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
  • 3
  • 3
6 Comments
 
LVL 6

Accepted Solution

by:
jpk041897 earned 200 total points
ID: 1220773
There are two approaches you can take to establish communication between a Java Applet or Server and an App running on Win16:

The first and simplest is to use a 16 bit winsock on Win16 (like Trumpet or Netsoft Chameleon)  and establish socket communication (either TCP or UDP) . Once the socket is established communication is straightforward.

Tere are a few limitations though:

- Win16  boxes can act as clients or servers, but are unable to function as both simultaneously. I.e.: You can run a clent application OR a server application on the box at any given time, but not both.

- Win16 based comertial languages do not include Winsock libraries, you would have to purchase one. I know Netsoft has one and I belive there might be a couple of sharware libs. arround.

- Socket programming under Win16 uses the WInsock 1.0 specs. WIn32 apps use 1.1 or above.

- Socket programing, although not very dificult, does require a lot of work.

The second approach is to use RPC's on the Win16 side and CORBA on the Java side. This solution shares all the limitations specified for winsock, with one exception. RPC  programming requires you to define an NIDL file (Network Interface Definition Language) to create the stubs that the app is going to use to establich communication. Once you have that working the rest is trivial.

Which option you chose depends on what you want to do. Use sockets for file and data transfer and RPC's for Remote Method Invocation.

Notes:

Java RMI is still in the alfa stage, although eisyer to use than CORBA, it is still unstable enough to warrant avoiding it for serious development efforts.

Although I believe I read somwhere that efforts were being made to provide a 16 bit version of Java, such versions are reputet not to support the java.net.* package.


I believe this adresses the main part of your question, but fel fre to add comments requesting further details if you need them.


0
 

Author Comment

by:Balaji052397
ID: 1220774
thanks for answering my question ,could u suggest a good book
for reading about these RPC's RMI's etc.
0
 
LVL 6

Expert Comment

by:jpk041897
ID: 1220775
I learned RPC using UNIX about  5 years ago so most of the books I used to leran RPC programming are out of print now. :-)

One of the best one is still arround thouh, its called:

Power Programming with RPC.

By John Bloomer
1st Edition February 1992
0-937175-77-3, Order Number: 773
522 pages, $29.95

You can get it dirrectly from  O'rielley at:

http://www.ora.com

or from Amazon (probably cheaper) at:

http://www.amazon.com

Regarding RMI and Corba, sice I allready knew RPC, I learned what I needed from the DOCS and scattered articles on the Net.

You can run a search for titles on Amazon or you could post a 10 point question for books that are a lot more up to date than my collection is.
0
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!

 

Author Comment

by:Balaji052397
ID: 1220776
could u give me a hardcoded Rpc sample sever and client
application where
client asks for the time
Server gives the current time
0
 
LVL 6

Expert Comment

by:jpk041897
ID: 1220777
Not as simple as taht I'm afraid. RPC's use a language called IDL (Interface definition Language) that generate stub code.

Stubs are combinations of header files and code files that are added to an application so that it (the application) can call the RPC libraries.

Send me an e-mail to:

jkelleghan@usa.net

and I'll gladdly send you some samples over e-mail, Even the smallest uses to many files to be conviniently posted here.

Regarding additional referances; Do you have access to the MS network CD or the Visual C++ standard (or better) edditions?

They contain all the info and samples you could ever need for RPC programming.
0
 

Author Comment

by:Balaji052397
ID: 1220778
Thank u for the suggestions , i have got vc++ 5.0 CD ,I will
search for RPC in that ,I also have got MSDN CD,Will search thro
that too.
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

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

Suggested Solutions

Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues unde…
In this post we will learn different types of Android Layout and some basics of an Android App.
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses

752 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